B2016-055 - Answering No to a dialog when doing a paste replace of a procedure was causing the code to crash.
B2016-048 - Editing an existing transition was causing the code to crash.
This commit is contained in:
parent
967e856f0c
commit
74f2b180eb
@ -75,6 +75,7 @@ namespace VEPROMS.CSLA.Library
|
||||
"\r\n\r\nSubsteps with Problem Transitions:" +
|
||||
exTrans.Summarize(),
|
||||
"Cannot Delete This Step", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
|
||||
if (ans == DialogResult.No) return this;// If answer "NO" then return self
|
||||
if (ans == DialogResult.Yes)
|
||||
{
|
||||
return exTrans[0].MyContent.ContentItems[0];
|
||||
@ -2031,6 +2032,7 @@ namespace VEPROMS.CSLA.Library
|
||||
catch (Exception ex)
|
||||
{
|
||||
ItemInfo iii = itemInfo.HandleSqlExceptionOnDelete(ex);
|
||||
if (iii == itemInfo) return null;// If self returned then return null
|
||||
if (iii != null) return iii;
|
||||
if (!HandleSqlExceptionOnCopy(ex))
|
||||
{
|
||||
|
@ -63,8 +63,9 @@ namespace Volian.Controls.Library
|
||||
_II_IncStepNumber=cbIncStepNum.Checked;
|
||||
_II_Procedure=cbTranProcs.SelectedIndex;
|
||||
_II_Section=cbTranSects.SelectedIndex;
|
||||
if (tvTran.SelectedNode != null && tvTran.SelectedNode.Tag != null)
|
||||
_II_ItemID=(tvTran.SelectedNode.Tag as ItemInfo).ItemID;
|
||||
// Use VEObject
|
||||
if (tvTran.SelectedNode != null && (tvTran.SelectedNode as VETreeNode).VEObject != null)
|
||||
_II_ItemID = ((tvTran.SelectedNode as VETreeNode).VEObject as ItemInfo).ItemID;
|
||||
}
|
||||
private bool SettingsChanged
|
||||
{
|
||||
@ -76,7 +77,8 @@ namespace Volian.Controls.Library
|
||||
if (_II_IncStepNumber != cbIncStepNum.Checked) return true;
|
||||
if (_II_Procedure != cbTranProcs.SelectedIndex) return true;
|
||||
if (_II_Section != cbTranSects.SelectedIndex) return true;
|
||||
if (_II_ItemID != (tvTran.SelectedNode.Tag as ItemInfo).ItemID) return true;
|
||||
// Use VEObject
|
||||
if (_II_ItemID != ((tvTran.SelectedNode as VETreeNode).VEObject as ItemInfo).ItemID) return true;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@ -961,7 +963,8 @@ namespace Volian.Controls.Library
|
||||
{
|
||||
if (_InitializingTrans) return;
|
||||
E_TransUI etm = (E_TransUI)_CurItemFrom.ActiveFormat.PlantFormat.FormatData.TransData.TransTypeList[listBoxTranFmt.SelectedIndex].TransUI;
|
||||
if ((etm & E_TransUI.StepAllowNone) == E_TransUI.StepAllowNone && tvTran.SelectedNode.Tag==null)
|
||||
// Use VEObject
|
||||
if ((etm & E_TransUI.StepAllowNone) == E_TransUI.StepAllowNone && (tvTran.SelectedNode as VETreeNode).VEObject == null)
|
||||
{
|
||||
bool isenh = MyRTB != null && MyRTB.MyItemInfo != null && MyRTB.MyItemInfo.IsEnhancedStep;
|
||||
btnTranSave.Enabled = !isenh && UserInfo.CanEdit(MyUserInfo, Mydvi); //Can Insert Transitons
|
||||
|
Loading…
x
Reference in New Issue
Block a user