 |
QuantShare
2010-10-02 06:40:39
0
|
|
Best Answer
To make a copy of a symbol you should create a global script.
- Select Tools -> Script Editor
- Create a new file then paste the following code:
Chart chart = Charts.GetSelectedChart();
if(chart != null)
{
string newsymbol = chart.SymbolName + "_Copy";
HistoricalQuotes data = Quotes.GetHistoricalQuotes(chart.SymbolName);
Symbols.AddSymbol(newsymbol);
data.Symbol = newsymbol;
data.OpenInterest = new double[data.Close.Length];
Quotes.SaveHistoricalQuotes(data);
}
- The script will detect the active chart symbol and create a copy of this symbol (SymbolName_Copy)
- To add this script to the bookmark panel:
-> Right click on that panel (under the drawing tool buttons)
-> Select "Script" then click on "OK"
-> Select the file you have previously created
Now, in order to create a copy of a symbol, simply double-click on that bookmark icon.
|
|