コード例 #1
0
        // checkbox event handler
        private void clickEvent_Click(object sender, EventArgs e)
        {
            SourceGrid.CellContext context = (SourceGrid.CellContext)sender;
            int iSel = context.Position.Row - 1;

            if (!_analysis.HasSolutionSelected(iSel))
            {
                _analysis.SelectSolutionByIndex(iSel);
            }
            else
            {
                _analysis.UnselectSolutionByIndex(iSel);
            }
        }
コード例 #2
0
 private void btSelectSolution_Click(object sender, EventArgs e)
 {
     try
     {
         int iSel = GetCurrentSolutionIndex();
         if (-1 == iSel)
         {
             return;
         }
         if (!_analysis.HasSolutionSelected(iSel))
         {
             _analysis.SelectSolutionByIndex(iSel);
         }
         else
         {
             _analysis.UnselectSolutionByIndex(iSel);
         }
     }
     catch (Exception ex)
     {
         _log.Error(ex.ToString());
     }
 }