Exemple #1
0
 private void destLines_SelectedIndexChanged(object sender, EventArgs e)
 {
     foreach (LineControl slc in srcLineControls)
     {
         slc.Parent.Controls.Remove(slc);
     }
     srcLineControls.Clear();
     if (destLines.SelectedIndex == -1)
     {
         destLineControl.Line = null;
         dline = null;
     }
     else
     {
         dline = mix.DestinationLines[destLines.SelectedIndex];
         destLineControl.Line             = dline;
         srcLineControlContainer.RowCount = dline.SourceLineCount;
         srcLineControlContainer.RowStyles.Clear();
         int sumHeight = 0;
         for (int i = 0; i < dline.SourceLineCount; i++)
         {
             LineControl slc = new LineControl();
             slc.Line = dline.SourceLines[i];
             srcLineControlContainer.RowStyles.Add(new RowStyle(SizeType.Absolute, slc.PreferredHeight));
             sumHeight += slc.PreferredHeight;
             srcLineControlContainer.Controls.Add(slc, 0, i);
             srcLineControls.Add(slc);
             slc.Dock = DockStyle.Fill;
         }
         srcLineControlContainer.Height = sumHeight;
     }
     UpdateMux();
 }
Exemple #2
0
        public void OutputLineShouldFail(string date, string compte, string libelle, double?debit, double?credit)
        {
            var lineDate = DateTime.MinValue;

            if (!string.IsNullOrWhiteSpace(date))
            {
                lineDate = DateTime.Parse(date);
            }

            Compte numeroCompte = null;

            if (!string.IsNullOrWhiteSpace(compte))
            {
                numeroCompte = new Compte(compte);
            }

            var line = new DestinationLine(lineDate, numeroCompte, libelle, (decimal?)debit, (decimal?)credit);
        }