Directly on the example, with some logo can simplify some judgment operation!
case 2: //logo int is1in3 = 0; int isBreak = 0; var selectlineid = ""; for (int k = 1; k <= userobjectform.saleship_lines1s.matrix.rowcount; k++) { ckbchoose = userobjectform.saleship_ LINES1s.Matrix.Columns.Item ("112"). Cells.item (k). specific as checkbox; if ( ckbchoose.checked) { isBreak = 1; } } if ( ISBREAK&NBSP;==&NBSP;1) { for (Int i = 1; i <= userobjectform.saleship_ lines1s.matrix.rowcount; i++) { ckbchoose = userobjectform.saleship_ LINES1s.Matrix.Columns.Item ("112"). Cells.item (i). specific as checkbox; if (ckbchoose.checked) { & nbsp; selectlineid = (UserObjectForm.SALESHIP_LINES1s.Matrix.Columns.Item ("1"). Cells.item (i). Specific as edittext). value; } } for (Int i = 1; i <= userobjectform.saleship_ lines2s.matrix.rowcount; i++) { var LineId1 = (Userobjectform.saleship_ LINES2s.Matrix.Columns.Item ("1"). Cells.item (i). Specific as edittext). value; if ( Convert.ToInt32 (Selectlineid) == convert.toint32 (LINEID1)) { is1In3 = 1; break; } } if (is1in3 == 1) { context.application.messagebox ( "Deleted rows and shipping have the same data, please first delete the row data in the shipment", 1, "", "", ""); bubbleEvent = false; } else { userobjectform.saleship_lines1s.removerow (); break; } } else { context.application.messagebox ( "must tick one line first!" ", 1, " ", " ", " "); bubbleEvent = false; }
Use the logo to judge