It is not that difficult. This seems difficult because there are many different ways to do this.
Try the following:
<TabControl x:Name="documentArea"/>
Handler for the AddForm button:
private void AddFormClick(object sender, RoutedEventArgs e) { object form = GetNewForm(); documentArea.Items.Add(form); }
What is it. You must implement GetNewForm() one of two ways. Ask him to return the user control that displays the form.
Or better yet, return the document you want to display. Use the DataTemplate to select the controls used to display this document. This method will be more difficult to configure.
source share