ScrewTurn

Active Trader Strategies API Community ChartStyles Community Commissions Community Components Community Indicators Knowledge Base Misc Optimizers PosSizers Providers Standard Indicators TASC Traders Tips TASCIndicators Tutorial Videos Visualizers
RSS

Navigation







Quick Search
»
Advanced Search »

PoweredBy

Syntax

public Dictionary<string, List<string>> FindSymbols(string symbols)

Parameter Description

symbols Symbol name (or a list of symbols) to find

Description

Sometimes, you need to know which DataSet(s) contain some particular symbol name(s). This function lets you find DataSets which include a given symbol. Passing a list of symbols is also supported.

When passing multiple symbol names, separate them with one of these characters: comma (','), semicolon (';'), or space (' '). (Consequently, space couldn't be a part of the symbol name.)

A Dictionary is returned, where the Key collection contains symbol name(s), and the Value collection contains the list of DataSet names where a corresponding symbol name was found.

Example

Check out this example which makes the function's usage easy:


using System;
using System.Windows.Forms;
using System.Collections;
using System.Collections.Generic;
using System.Text;
using System.Drawing;
using Community.Components;
using WealthLab;

namespace WealthLab.Strategies { public class SearchForClickedSymbol : WealthScript { protected override void Execute() { Utility u = new Utility(this); ClearDebug();

// Dialog to manually input some symbol(s) string symbols = Utility.Input(); // FindSymbols output Dictionary<string, List<string>> result = new Dictionary<string, List<string>>(); result = u.FindSymbols(symbols); foreach( KeyValuePair<string, List<string>> kvp in result ) { //Looping by each symbol... PrintDebug("Symbol: " + kvp.Key); // ...display every DataSet found foreach( string ds in kvp.Value ) PrintDebug("DataSet name: " + ds); } } } }

Important Disclaimer: The information provided by Wealth-Lab is strictly for informational purposes and is not to be construed as advice or solicitation to buy or sell any security.  The owner of Wealth-Lab.com assumes no liability resulting from the use of the material contained herein for investment purposes.

Used under license from FMR Corp. Copyright 2008 FMR Corp. All rights reserved.


ScrewTurn Wiki version 3.0.2.509. Some of the icons created by FamFamFam.