回复 1楼menghuanyunxia的帖子
请问您指的是通过 Ctrl + V 快捷键粘帖吗?如果是,可以使用以下方法定制快捷键行为,以下代码定制了只复制数据,不包括任何格式信息:
- FarPoint.Win.Spread.InputMap inputmap1;// Assign the InputMap object to the existing map.
- inputmap1 = fpSpread1.GetInputMap(FarPoint.Win.Spread.InputMapMode.WhenAncestorOfFocused);
- inputmap1.Put(new FarPoint.Win.Spread.Keystroke(Keys.V, Keys.Control), FarPoint.Win.Spread.SpreadActions.ClipboardPasteValues);
- FarPoint.Win.Spread.InputMap inputmap2;
- inputmap2 = fpSpread1.GetInputMap(FarPoint.Win.Spread.InputMapMode.WhenFocused);
- inputmap2.Put(new FarPoint.Win.Spread.Keystroke(Keys.V, Keys.Control), FarPoint.Win.Spread.SpreadActions.ClipboardPasteValues);
复制代码 |