版主:
//黏贴
// im.Put(new FarPoint.Win.Spread.Keystroke(Keys.V, Keys.Control), FarPoint.Win.Spread.SpreadActions.ClipboardPasteAsStringSkipHidden);
//复制
// im.Put(new FarPoint.Win.Spread.Keystroke(Keys.C, Keys.Control), FarPoint.Win.Spread.SpreadActions.ClipboardCopyAsStringSkipHidden);
复制粘贴代码修改后
会造成粘贴事件中取范围永远只能取到一行,无法取到多行。
var Range = e.CellRange;
SheetView view = MainSpread.GetActiveSheet();
int intMainPlanNo = GetColumnIndex(view, "主计划号");
var StarRowRange = MainSpread.GetActiveSheet().GetSpanCell(Range.Row, intMainPlanNo);
var EndRowRange = MainSpread.GetActiveSheet().GetSpanCell(Range.Row + Range.RowCount - 1, intMainPlanNo);
中的“var Range = e.CellRange;”永远只有一条数据,请帮忙解决,谢谢! |