Watchlist Trick? (Modifying WatchListProvider DataSets)
Author: hlh
Creation Date: 7/6/2011 9:08 AM
profile picture

hlh

#1
Having several DataSets changing every quarter I would like to use them generating Watchlists over the same symbols but from ASCII source intraday files which hold over 2000+ symbols. As such DataSets or portfolios how I call them can consist of 300 to 400 symbols it is cumbersome or almost impossible to manually check and add each symbol from the 2000+ list to a Watchlist.

I was trying to build a new watchlist holding only a couple of symbols from that intraday ASCII list and then to replace the relating XML file I found with the 300 to 400 symbols changing the sections
CODE:
Please log in to see this code.
. Well this did not work our as expected. I still have the couple of symbols I used to create that Watchlist.

Any idea how I could get this Watchlist trick to work or any other idea how to create Watchlists or kind of DataSets without duplicating the already huge ASCII files over and over again? Thank you!
profile picture

Eugene

#2
Moving this to Extensions section since the WatchList provider's an extension (and only it has this XML structure).

Assuming that both the DATASETnnn and rowOrder are unique and matching (and XML structure is valid i.e. all tags were closed properly like on the example above), the only thing I can think of is that you haven't restarted WL6. No changes to DataSets made externally (i.e. not by the StaticProvider instance created by Wealth-Lab itself) will be reflected until WL is restarted. This has been the design.
profile picture

hlh

#3
Thank you for your feedback. I was thinking/hoping that DATASETnnn simply starts with 1 and rowOrder with 0 and that is relevant for the new Watchlist? Or is DATASET and rowOrder somehow related to the source?

I just was looping thru all my symbols of the existing DataSets and writing text like shown above incrementing both DATASET and rowOrder?

I also did not look in the "header" of the XML if there is anything to change too, like the total number of symbols, etc.?
profile picture

Eugene

#4
Although we haven't been involved in the development of the Watchlist provider, my impression is that:

1. DATASET starts from DATASET1,
2. rowOrder starts from 0, and
3. the header doesn't seem to store the total number.

I've just built a Watchlist of 2 symbols from different DataSets, closed WL, added a 3rd symbol manually by mangling with the XML, restarted WL and it worked fine. So, it seems that you can do manual edits while WL is closed, making sure that the XML structure stays valid and there's no DATASET/rowOrder collision.
profile picture

hlh

#5
I got it. I mixed something up. One can even see it by looking at my XML code lines above.

Hard to find, even worse than writing a wrong number in an Extreme Killer Sudoku and try to find it! Everyone who finds it within 5 minutes can call him/herself Extreme XML king/queen. ;-)

So it is working! For those interested, I attach the relevant parts of my test script. So far, it only writes it to the Debug Window but can be copy/paste to the respective Watchlist XML file.

CODE:
Please log in to see this code.
profile picture

Eugene

#6
QUOTE:
One can even see it by looking at my XML code lines above.

Oh yeah, now I do. The Source and Symbol tags are intermixed.
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).