B2026-016 Fix Error Approving a Procedure without ROs set

This commit is contained in:
2026-02-24 07:08:07 -05:00
parent db3d9fc65f
commit 7f36a33dea
2 changed files with 18 additions and 3 deletions

View File

@@ -1312,7 +1312,15 @@ namespace VEPROMS
pi.MyDocVersion.DocVersionConfig.SelectedSlave = 0;
if (si.IsApproved == 1)
{
dlgExportImport dlg = new dlgExportImport("Export", pi, MyFrmVEPROMS, (selectedSlave)); // "true tell export to convert ROs and Transitions to text
//B2026-016 - Fix error pulling Reference Object info into Export
if (pi.MyDocVersion.DocVersionAssociationCount == 0)
{
MessageBox.Show("Prior to Approval you must set the Referenced Object Database", "No RO Database set", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
return false;
}
dlgExportImport dlg = new dlgExportImport("Export", pi, MyFrmVEPROMS, (selectedSlave)); // "true tell export to convert ROs and Transitions to text
dlg.DocReplace = frm.DocReplace; // this tells approval to prepare an export file with resolved transitions and ROs, word sections are saved with resolved ROs during approval PDF creation and saved in DocReplace
System.Xml.XmlDocument xd = new System.Xml.XmlDocument();
dlg.ExportItem(xd, pi, "procedure");