keypressEdit事件,代码修改成
If e.Col.Name = "客户ID" Then '如果编辑的是客户ID列 If e.Col.DroppedDown = False '且下拉窗口没有打开 'e.Col.OpenDropDown() '打开下拉窗口 Sendkeys.Send("{F4}") End IfEnd If