Fixed a delete step issue where if there were transitions that needed deleted or re-assigned, you would get trapped in an infinite loop, constantly displaying the error message.
This commit is contained in:
parent
fa261f2f00
commit
425617eeec
@ -840,6 +840,11 @@ namespace Volian.Controls.Library
|
||||
//private void HandleSqlExceptionOnDelete(System.Data.SqlClient.SqlException ex)
|
||||
private void HandleSqlExceptionOnDelete(Exception ex)
|
||||
{
|
||||
this.MyStepRTB.InsertSymbol(@"\u160?"); // since text was deleted, insert a hard space to prevent a looping effect B2016-082
|
||||
using (Item itm = MyStepRTB.MyItemInfo.Get())
|
||||
{
|
||||
Annotation x = Annotation.MakeAnnotation(itm, AnnotationType.GetByName("Verification Required"), null, "A Hard Space was put in to keep the Transitions referencing here valid. \nPlease remove or re-assign these transitions before deleting this step.", null);
|
||||
}
|
||||
if (ex.Message.Contains("has External Transitions and has no next step"))
|
||||
{
|
||||
using (TransitionInfoList exTrans = TransitionInfoList.GetExternalTransitions(MyID))
|
||||
@ -852,7 +857,6 @@ namespace Volian.Controls.Library
|
||||
if (ans == DialogResult.Yes)
|
||||
{
|
||||
MyStepPanel.MyStepTabPanel.MyDisplayTabControl.OpenItem(exTrans[0].MyContent.ContentItems[0]);
|
||||
|
||||
}
|
||||
else
|
||||
SetFocus();
|
||||
|
Loading…
x
Reference in New Issue
Block a user