|
-
Oct 13th, 2000, 11:38 AM
#1
How would you go about setting focus to a new cell whenever a user has inserted a record? For example, every time the user press ENTER after inserting a record, a new row automaticlly display and is ready for another new recorder for input, I want the new row to have the focus (1st coloumn) so that the user doesn't need to use the mouse to set it. Any idea? I am totally new on dbgrid. I am using adodc with the dbgrid. Thanks!
-
Oct 13th, 2000, 11:52 AM
#2
Nevermind.... I figured it out. Thanks!
-
Oct 16th, 2000, 07:40 AM
#3
Addicted Member
I have this problem in my app, please let me know how did you figured it out, Thanks in advance
-
Oct 18th, 2000, 09:19 AM
#4
In the dbgrid property, under keyboard tab, select WrapCellPointer and in the TabAction - dbgGridNavigation.
Hope this help.
-
Oct 21st, 2000, 02:04 AM
#5
Addicted Member
Thank you for your reply
I tried what you suggested and still did not work, Look at my AddNew click event, It may have a problem..What do you think about???
Private Sub AddNew_Click()
Data1.Recordset.MoveLast
DBGrid1.AllowUpdate = True
DBGrid1.AllowAddNew = True
DBGrid1.SetFocus
End Sub
Thanks
-
Oct 21st, 2000, 03:02 AM
#6
Addicted Member
I add the one line and it works fine..
Private Sub AddNew_Click()
Data1.Recordset.MoveLast
DBGrid1.AllowUpdate = True
DBGrid1.AllowAddNew = True
DBGrid1.SetFocus
DBGrid1.Row = DBGrid1.Row + 1
End Sub
You may have better way..
Thanks
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|