Marked as 'AdvertsingProfitControl v 0.8.5' by its folder name. The 'Add Records' form has been finshed to at least include all the information the Advertising Profit Control sheet had.
This commit is contained in:
@@ -0,0 +1,39 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace AdvertsingProfitControl
|
||||
{
|
||||
class ExecuteCommand
|
||||
{
|
||||
|
||||
public DataGridViewRow ExecuteRepeatCommand(DataGridViewRow targetRow)
|
||||
{
|
||||
DataGridViewRow copiedRow = new DataGridViewRow();
|
||||
|
||||
foreach (DataGridViewCell cell in targetRow.Cells)
|
||||
{
|
||||
copiedRow.Cells.Add(cell);
|
||||
}
|
||||
|
||||
return copiedRow;
|
||||
}
|
||||
|
||||
public DataGridViewRow[] ExecuteRepeatCommand(DataGridViewRow[] targetRows)
|
||||
{
|
||||
DataGridViewRow[] copiedRows = new DataGridViewRow[targetRows.Length];
|
||||
int i = 0;
|
||||
foreach (DataGridViewRow row in targetRows)
|
||||
{
|
||||
foreach (DataGridViewCell cell in row.Cells)
|
||||
{
|
||||
copiedRows[i].Cells.Add(cell);
|
||||
}
|
||||
i++;
|
||||
}
|
||||
|
||||
return copiedRows;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user