I have a customization in the Equipment Maintenance form. I am using UD100 and UD100A for additional information linked to the Equipment in the form. I am trying to update fields in UD100 and UD100A and I can’t get those fields in UD100A to update but, I can get UD100 fields to update. Can anyone see what I am missing in my code and why the 100A won’t update?
private void CallUD110AdapterGetByIDMethod()
{
try
{
UD110Adapter adapterUD110 = new UD110Adapter(this.oTrans);
adapterUD110.BOConnect();
string Key1 = "PMOPERATIONS";
string Key2 = tbFreqCodeBase.Text;
string Key3 = tbTypeCodeBase.Text;
string Key4 = tbEquipTypeID.Text;
string Key5 = string.Empty;
string childKey1 = "OPERINSTRUCT";
string childKey2 = tbInstNum.Text;
string childKey3 = string.Empty;
string childKey4 = string.Empty;
string childKey5 = string.Empty;
MessageBox.Show("Key1: " + Key1.ToString() + "Key2: " + Key2.ToString() + "Key3: " + Key3.ToString() + "Key4 " + Key4.ToString() + "Key5: " + Key5.ToString());
bool result = adapterUD110.GetByID(Key1, Key2, Key3, Key4, Key5);
adapterUD110.UD110Data.UD110[0].Character01 = tbPMSpecialTools1.Text;
adapterUD110.UD110Data.UD110A[0].Character01 = tbPMSpecialTools1.Text;
adapterUD110.UD110Data.UD110A[0].Character02 = tbPMInstruction1.Text;
adapterUD110.UD110Data.UD110A[0].CheckBox01 = epiCheckBox1.Checked;
adapterUD110.Update();
adapterUD110.Dispose();
} catch (System.Exception ex)
{
ExceptionBox.Show(ex);
MessageBox.Show("PMS Instruction wasn't updated");
}
}