I want to create textboxes in xaml file upon a button click through the .xaml.cs file from a loop (probably). I've calculated the margins for each textbox to appear in the panel but do not know how to bind the code. Here's the image of the xaml design view and what I'm trying to achieve. The window will have one textbox for choices appear and the loop will create another and another each time the add choice button is clicked.
Can anyone please help? I'm just learning wpf. Thank you