- ago
I was going through the documentation on writing a wealth lab client extension:
https://www.wealth-lab.com/Support/ExtensionApi/WealthLabClientExtension

I will like to execute some other strategies for a symbol from WL client extension. I could not find any method in IHost which can execute a strategy. Is there some other interface or class which has methods to execute a strategy or if there is any other way to achieve this?
0
119
6 Answers

Reply

Bookmark

Sort
- ago
#1
Let's first find out why you think you need to run a strategy this way?
0
- ago
#2
I have another program which I use for journaling and portfolio management. When a symbol is selected in the external program, I want to display the chart with some standard indicators and custom indicators and annotations in WealthLab for which I already have a strategy script coded. I was trying to use WealthLab Client Extension feature for this. But if there is a better way to achieve this, I am open to it.

But this is a very general question on being able to integrate various tools in our personal trading suite of tools and for that there should be a way to communicate/link between each other. The simplest thing would be to allow a script to be run from another program. I can send signals to other tools from WealthLab by just making a REST api call to those tools. If WealthLab can have simple REST api calls like IB Trader Workstation to execute strategy script or may be more actions, then that will even be more awesome! We can have iPad apps calling those apis :) I was thinking why we don't have iPad mobile app to see the amazing charts generated by WealthLab, given all stock charting software now have mobile versions.
0
- ago
#3
Thanks for the detailed description. Have you considered using a macro tool like AutoIT to make actions within WL7?
https://stackoverflow.com/questions/7834369/autoit-with-wpf#7834404

If we ever get to consider implementing something like this we should be cautious to not open the door for some dodgy usage of WL7's DLLs in 3rd party applications without proper authentication of the paid subscriber.
0
- ago
#4
Thanks Eugene for pointer on Macro tool or UI automation! Will look into those options. This will be my last option as the problem with UI automation is that they are very sensitive to delays and so putting long delays and leaving unattended makes more sense for these. But if I get motivated enough and have time, I will look into this.

I understand concerns around using WL dlls without paying. You can probably make sure that before any hooks/apis are called, WL UI starts completely along with license check. Personally, I have no issues paying the current license fees as it saves me lot of time in my trading, post-analysis, and backtesting and it has got couple of unique features which I haven't found anywhere else.
0
- ago
#5
By analogy with WL6, GetChartBitmap required context and could not be used for multi-symbol backtests in "headless" mode i.e. without user having to click through all the DataSet symbols. There may be a similar obstacle ahead of your task of running a strategy in headless mode to generate bitmaps. I admit I haven't looked into it yet and so may not be aware of the implementation details completely so Dion will correct me if I'm wrong.
0
- ago
#6
I am actually not looking for headless mode. And I also do not want to get the Bitmap (although that will be a nice feature to have). I am looking to just run a strategy from an external program either through some REST api or through some .net remoting or the old COM. Something like this:
REST API:
CODE:
http://localhost:7293/wealtlab/runScript?scripName=MyStrategy/MyScript&symbol=AAPL&timeFrame=Daily

or
.NET Remoting/COM:
CODE:
wealthlab.runStrategy("MyStrategy/MyScript", "AAPL", "Daily")


The flow will be like this:
1. I start WealthLab (and may be select an option to run a REST api on a port)
2. I open a strategy
3. In my external program, I click on a symbol. This sends the event (may be REST api call or .net remoting or COM) to WealthLab and WealthLab runs the strategy with that particular symbol and displays the chart.
0

Reply

Bookmark

Sort