I have a CaseForm with these controls placed in it. UserControl1 is above UserControl2.
TabControl1 has UserControl1
TabControl2 has UserControl2
UserControl1-upon btnSave(), it generates a new case number and a new caseID. Which saves to db. This works fine.
The caseID is the key ID for both. UserControl2 case is part of the UserControl1 case.
A case has to be created in UserControl1, in order to create a new subcase in UserControl2. It needs to pass the caseID to it.
Now I get null object error in my Save() here:
CaseRecord.SubCase.CaseID = CaseRecord.CaseID.Value;
How do I pass the caseID from UserControl1 to UserControl2 to save.
Thank you for any help!