Пример #1
0
 /// <summary>
 /// //////////////////////////////////////////////////////////////////////////////
 /// </summary>
 private void buttonMultiply_Click(object sender, EventArgs e)
 {
     try
     {
         if (ColA != RowB)
         {
             MyMessageBox.Show("Không thỏa điều kiện thực hiện phép nhân");
         }
         else
         {
             GlobalsMatrix.nhan();
             Add_MatrixRe(RowA, ColB);
             GlobalsMatrix.setRowMatrixRe(RowA);
             GlobalsMatrix.setColMatrixRe(ColB);
             RowR = GlobalsMatrix.RowRe;
             ColR = GlobalsMatrix.ColRe;
             if (RowR >= 5 && ColR >= 5)
             {
                 flowLayoutPanelR.FlowDirection = FlowDirection.LeftToRight;
             }
             else
             {
                 flowLayoutPanelR.FlowDirection = FlowDirection.TopDown;
             }
         }
     }
     catch (Exception ex)
     {
         MyMessageBox.Show(ex.Message);
     }
 }
Пример #2
0
 private void buttonMultiply_Click(object sender, EventArgs e)
 {
     try
     {
         if (ColA != RowB)
         {
             MyMessageBox.Show("Không thỏa điều kiện thực hiện phép nhân");
         }
         else
         {
             GlobalsMatrix.nhan();
             GlobalsMatrix.setRowMatrixRe(RowA);
             GlobalsMatrix.setColMatrixRe(ColB);
             MyMessageBox.Show("Đã nhân hai ma trận");
         }
     }
     catch (Exception ex)
     {
         MyMessageBox.Show(ex.Message);
     }
 }