User Control inside the Tabitem in wpf using mvvm
I am using WPF MVVM model in my project using C#.Net.
I am trying to use usercontrol inside the tabitem.
When i run the project I cannot access usercontrol. It displays error "Value cannot be null. No parameter element".
I have attached my XAML and ViewModel Code for your reference.
XAML Code:
==========
<TabItem x:Name="tabitemApplicantDetails" Style="{StaticResource SimpleTabItem}" Background= "#D0B71F"
Header="Applicant Details">
<UserControl x:Name="UserControlApplicantDetails" Height="592" Width="931">
View Model:
==========
WindowElement winElement = GetWindowElement.GetElement(Collection.FormApplicantDetails);
UserControl userControl = Getchild.GetField(Collection.ApplicantUserControl, Collection.ApplicantUserControlName) as
UserControl;
if (DataValidator.IsValid(userControl))
{
}
Please advise.