在DataGrid里按回车键不能自动移动到下一个,有办法解决吗?
解决方案 »
- 求助~~TEXT问题~
- 如何将SQLServer表里的 Image型字段另存成硬盘上图片文件
- 请问Visual Basic6中怎样查找ACCESS数据库中的相应记录,并将查找结果显示在相应的文本框中
- 請問這是什麽問題(The object invoked has disconnected from its clients)
- 用ado连接DBF文件时产生"外部表不是预期的格式"的错误,如何解决?
- 为什么我做的程序在2000下可以正常运行,可在98+vb6的运行环境下就出现“找不到工程和库”的错误,帮忙!
- !!!我要关机!!!
- 请教:关于SQL查询
- 物业管理系统(网络版)
- 请问用sql语句 select 数据库的时候,怎样作两层的排序?就是先按type的从小到大排列,然后从中有按时间排序?
- 向大家请教个小问题:怎样打开excel文件?在线等候,一回答就感谢你!
- shell_notifyicon API,提示找不到DLL入口的信息
你是要加數據時候移動還是在瀏覽數據時候﹐移動到下一條?
Private Sub DataGrid1_KeyPress(KeyAscii As Integer)
Dim I As Long
If KeyAscii = 13 Then
I = DataGrid1.Row()
DataGrid1.Row = I + 1
End If
End Sub
Private Sub DataGrid1_KeyPress(KeyAscii As Integer)
Dim I As Long
On Error Resume Next
If KeyAscii = 13 Then
I = DataGrid1.Row()
DataGrid1.Row = I + 1
End If
End Sub
On Error Resume Next
Dim row As Long, col As Long
row = DataGrid1.row
col = DataGrid1.col
If KeyAscii = 13 Then
If DataGrid1.col = DataGrid1.Columns.Count - 1 Then
DataGrid1.row = row + 1
DataGrid1.col = 0
Else
DataGrid1.col = col + 1
End If
End If
End Sub