Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
TextBlock in Grid
Collapse
X
-
Other Uses for an AddOn
//Create a sample text block and add it to the Top/Bottom Panel Grid.
TextBlockTextBlock=newTextBlock();
TextBlock.Text=PanelDirection.ToString()+" Panel ("+PanelLocation.ToString()+") Sample Text Block";
TextBlock.Foreground=Brushes.Red;
TextBlock.SetValue(Grid.RowProperty,0);
Panel.Children.Add(TextBlock);
I found the missing using,
but I still have an error in the placing of the text in a cell,
using example code from LONGSHORTButtons
trying to add a row for comments
Thanks
Comment
-
Hi kenz987,
The TextBlock would not be able to change after the page content is set and loaded. It would be best to use a switch statement to set the text before it is added to the window, or use a TextBox if you need to edit the text. I also attached a sample that demonstrates how to implement Model-View Model-View pattern in an Addon.
Please let me know if I can assist any further.Attached Files
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Geovanny Suaza, 02-11-2026, 06:32 PM
|
0 responses
630 views
0 likes
|
Last Post
|
||
|
Started by Geovanny Suaza, 02-11-2026, 05:51 PM
|
0 responses
364 views
1 like
|
Last Post
|
||
|
Started by Mindset, 02-09-2026, 11:44 AM
|
0 responses
105 views
0 likes
|
Last Post
by Mindset
02-09-2026, 11:44 AM
|
||
|
Started by Geovanny Suaza, 02-02-2026, 12:30 PM
|
0 responses
566 views
1 like
|
Last Post
|
||
|
Started by RFrosty, 01-28-2026, 06:49 PM
|
0 responses
568 views
1 like
|
Last Post
by RFrosty
01-28-2026, 06:49 PM
|

Comment