diff --git a/PROMS/Formats/fmtall/AEPall.xml b/PROMS/Formats/fmtall/AEPall.xml index 7737866b..30c6bdab 100644 Binary files a/PROMS/Formats/fmtall/AEPall.xml and b/PROMS/Formats/fmtall/AEPall.xml differ diff --git a/PROMS/Volian.Controls.Library/DisplayTransition.cs b/PROMS/Volian.Controls.Library/DisplayTransition.cs index 5672b537..6c027f3c 100644 --- a/PROMS/Volian.Controls.Library/DisplayTransition.cs +++ b/PROMS/Volian.Controls.Library/DisplayTransition.cs @@ -172,7 +172,7 @@ namespace Volian.Controls.Library if (secStartId > -1) { secitm = ItemInfo.Get(secStartId); - selitm = (secitm.Steps.Count > 0) ? secitm.Steps[0] : null; + selitm = (secitm.Steps != null && secitm.Steps.Count > 0) ? secitm.Steps[0] : null; } else btnTranSave.Enabled = false; // if there is an invalid section start - don't allow save. @@ -181,7 +181,7 @@ namespace Volian.Controls.Library // Fill step items, passing in the active step to the selected item, or the first // step if the selection was not at the step level. ItemInfo stpitm = null; - if (selitm.MyContent.Type >= 20000) + if (selitm != null && selitm.MyContent.Type >= 20000) { if (_DoingRange) @@ -504,7 +504,7 @@ namespace Volian.Controls.Library private void cbTranProcsFillIn(ItemInfo prcitm) { cbTranProcs.Items.Clear(); - ItemInfo selitm = prcitm; // this is the selected 'section' + ItemInfo selitm = prcitm; // this is the selected 'procedure' prcitm = prcitm.FirstSibling; while (prcitm != null) { @@ -747,7 +747,10 @@ namespace Volian.Controls.Library int sectstartid = FindSectionStart(_CurrentProcedure); if (sectstartid==-1) btnTranSave.Enabled = false; // if there is an invalid section start - don't allow save. IList chldrn = _CurrentProcedure.GetChildren(); - if (chldrn != null && chldrn.Count > 0) cbTranSectsFillIn((ItemInfo)chldrn[0], secitm==null?sectstartid:secitm.ItemID, true); //sectstartid); + int secIdForCbSect = secitm == null ? sectstartid : secitm.ItemID; + // if this transition format requires the default section, use it: + if ((etmnew & E_TransUI.SectDefault) == E_TransUI.SectDefault) secIdForCbSect = sectstartid; + if (chldrn != null && chldrn.Count > 0) cbTranSectsFillIn((ItemInfo)chldrn[0], secIdForCbSect, true); //sectstartid); } _TranFmtIndx = listBoxTranFmt.SelectedIndex; groupPanelTranFmt.Style.BackColor = (_CurTrans == null && _TranFmtIndx == 0) ? Color.Yellow : Color.Orange;