I am creating Dynamic Rectangle and adding into StackPanel. I need to add text to each rectangle. How can I do that?
StackPanel
You need to add a textual control to your StackPanel, such as Label or TextBlock.