Welcome to NexusFi: the best trading community on the planet, with over 150,000 members Sign Up Now for Free
Genuine reviews from real traders, not fake reviews from stealth vendors
Quality education from leading professional traders
We are a friendly, helpful, and positive community
We do not tolerate rude behavior, trolling, or vendors advertising in posts
We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community. It's free for basic access, or support us by becoming an Elite Member -- see if you qualify for a discount below.
-- Big Mike, Site Administrator
(If you already have an account, login at the top of the page)
I am using a code like this for the charttrader infos and it does fine as long as charttrader is enabled.
To be more specific: How to solve the above problem that occurs when charttrader is not enabled?
I am using a code like this for the charttrader infos and it does fine as long as charttrader is enabled.
To be more specific: How to solve the above problem that occurs when charttrader is not enabled?
Look at post #12. If chart trader is not visible, the objects do not exist, so you will get errors trying to access them. I use
if ( ChartControl.ChartTraderEnabled && ChartControl.ChartTraderVisible ) {
Blah...Blah
}
Look at post #12. If chart trader is not visible, the objects do not exist, so you will get errors trying to access them.
I have this error only at startup, change of timeframe etc. when CT is disabled.
But after starting with CT enabled, I can disable the CT and the CT items do exist. The same way as they exist when CT is disabled and you place an order with the right mouse on the chart, then the ATM Strategy and Quantity from CT is used.
Looks like I have to survive the OnStartup, and everything will be fine.
Thanks for code. This could solve the problem. Will test it.
Thanks for code. This could solve the problem. Will test it.
I did a quick test with this code:
if ( ChartControl.ChartTraderEnabled && ChartControl.ChartTraderVisible )
It did work without errors. At startup CT must be enabled, or use F5 after that.
Change timeframe, instrument with CT disabled works fine.
To change Account, Strategy, Quantity, the CT has to be enabled (that’s clear, as you want that stuff)
To make it perfect, a code to make CT enabled at startup would be the final point.
That’s just a first test, but IMO the results are promising.
I could not edit my last post to add a comment…. So I have to add a new one.
As the code is not a secret sauce you cannot expect a miracle. It is nice to take the “unsupported code” out of the game in situations where it would produce errors. That’s nice and very useful.
But you have to think more serious about whether charttrader info’s are up-to-date in your variables at a specific moment or not.
To have the code to show charttrader would be helpful. You can access the ShowCharttrader via coding the NT-HotKey. But NT named this HotKey wrong as it is not show-, but enablecharttrader.
Sometimes this “unsupported stuff” goes a baby step forward. That’s always great…