Registered User Joined: 6/15/2008 Posts: 1,356
|
Bruce, do you know a way to address the watchlist in realcode?
I want to export my watchlist to an external database.
I know how to export data in realcode to an external database, using a .Net namespace.
However I'd like to export the watchlist once a day.
If I can't address the watchlist, then I'd have to come up with a workaround, a "bogus" code that runs, let's say at 4pm, and that will be passing all tickers in the watchlist.
|
Registered User Joined: 12/31/2005 Posts: 2,499
|
Export a plot that just prints close on lastbar should give you something to work with
if lastbar then
plot close
endif
|
Registered User Joined: 6/15/2008 Posts: 1,356
|
Yea I know I can do something like that.
but Ideally I'd like something that would sense a change in the watchlist (ticker added/deleted), and only on that event export the list.
with a "if lastbar" condition I can loop al the tickers into an array, make the connection to the external database with System.data.oledb namespace , check if they're the same and if not, update the external database.
However this will be a condition that'll run all day long on my chart, and is unnecessary use of resources.
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
The only way I know of to 'touch" all of the symbols in a WatchList is to sort that WatchList or create a Custom Market Indicator. The suggestion by jas0501 to create a RealCode Indicator and just export it once a day seems like the best option.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|