Announcement
Collapse
Looking for a User App or Add-On built by the NinjaTrader community?
Visit NinjaTrader EcoSystem and our free User App Share!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less
Partner 728x90
Collapse
NinjaTrader
Button color state
Collapse
X
-
Doing that still doesn't work, because my problem is that with F5 it should keep the value at that moment and not set it to the standard value of the variable. If there were any status that would preserve the last value and would always remain even if you reloaded?
-
Hello anmir55,
The button itself does not have it's properties reservced.
You are preserving the values of DisplayCompletedLines and ColorFondoOff correctly.
However, you are not using these variables when the button is generated in AddButtonToToolbar().
Are you are not changing the brush that assigned to ColorFondoOff. It's preserved when hitting F5 but the value was never changed.Chelsea B.NinjaTrader Customer Service
Comment
-
Hello anmir55,
In AddButtonToToolbar(), when creating the button, check DisplayCompletedLines is false and set the _button.Background to black.
If you want ColorFondoOff to hold a different brush value, then assign ColorFondoOff a different brush value.Chelsea B.NinjaTrader Customer Service
Comment
-
Hello anmir55,
In AddButtonToToolbar(), when creating the button, check DisplayCompletedLines is false and set the _button.Background to black.
You are doing this check in OnButtonBuyClick(), but you are not doing this in AddButtonToToolbar().
If you want ColorFondoOff to hold a different brush value, then assign ColorFondoOff a different brush value.Chelsea B.NinjaTrader Customer Service
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by AaronKoRn, Today, 09:49 PM
|
0 responses
2 views
0 likes
|
Last Post
by AaronKoRn
Today, 09:49 PM
|
||
Started by carnitron, Today, 08:42 PM
|
0 responses
7 views
0 likes
|
Last Post
by carnitron
Today, 08:42 PM
|
||
Started by strategist007, Today, 07:51 PM
|
0 responses
8 views
0 likes
|
Last Post Today, 07:51 PM | ||
Started by StockTrader88, 03-06-2021, 08:58 AM
|
44 responses
3,975 views
3 likes
|
Last Post
by jhudas88
Today, 06:59 PM
|
||
Started by rbeckmann05, Today, 06:48 PM
|
0 responses
9 views
0 likes
|
Last Post
by rbeckmann05
Today, 06:48 PM
|
Comment