diff --git a/PROMS/VEPROMS User Interface/frmPSI.cs b/PROMS/VEPROMS User Interface/frmPSI.cs index e397dcbe..3d4363a7 100644 --- a/PROMS/VEPROMS User Interface/frmPSI.cs +++ b/PROMS/VEPROMS User Interface/frmPSI.cs @@ -79,9 +79,12 @@ namespace VEPROMS cb.Text = fld.text; cb.Location = new Point((int)fld.x * 2, (int)fld.y * 2); cb.Visible = true; + cb.Width = (int)fld.width * 2; string val = procConfig.GetValue("PSI", fld.name); cb.Checked = val!=null && val!="" && val.ToUpper()[0] == 'Y' ? true : false; this.Controls.Add(cb); + maxx = ((int)fld.x * 2 + (int)fld.width * 2) > maxx ? ((int)fld.x * 2 + (int)fld.width * 2) : maxx; + maxy = ((int)fld.y * 2 + (int)fld.height * 2) > maxy ? ((int)fld.y * 2 + (int)fld.height * 2) : maxy; } } if (psiDialogDef.ButtonsOnBottom == null || psiDialogDef.ButtonsOnBottom.ToUpper() == "NO") diff --git a/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs b/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs index b391de18..9494afae 100644 --- a/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs +++ b/PROMS/VEPROMS.CSLA.Library/Extension/ItemExt.cs @@ -2073,9 +2073,10 @@ namespace VEPROMS.CSLA.Library { int typ = (int)ActiveSection.MyContent.Type; int subtyp = typ % 10000; + if (subtyp >= ActiveFormat.PlantFormat.DocStyles.DocStyleList.Count) return ActiveFormat.PlantFormat.DocStyles.DocStyleList[0]; _MyDocStyle = ActiveFormat.PlantFormat.DocStyles.DocStyleList[subtyp]; - } - return _MyDocStyle; + } + return _MyDocStyle; } set { @@ -2307,7 +2308,9 @@ namespace VEPROMS.CSLA.Library // the ident of the step: bool useSubStepTabs = false; - if (doMeta && IsHigh && !seqtabs[(localPrintLevel<0?0:localPrintLevel) % seqtabs.Count].TabToken.Contains("{numericWpar}")) useSubStepTabs = true; + if (doMeta && IsHigh + && !seqtabs[(localPrintLevel<0?0:localPrintLevel) % seqtabs.Count].TabToken.Contains("{numericWpar}") + && tbformat.Contains("{")) useSubStepTabs = true; // Check to be sure the parent tab should be included... If this sequential is within a note // or caution or equipment list, don't use parent tab AND always start the numbering as a numeric