Hi Everyone
I'm nearly there, it's the last little bit that's got me stumped / flummoxed (adjective of choice).
I have a continuous list form which shows Tasks against Customers. On each row of the form there is a "Details" button which when clicked takes you to the Customer form like-
DoCmd.OpenForm "frmCstm", , , "[CstmID]=" & Me.CstmID, , , "Task" & CStr(Me.TaskID)
In the Form_Open section of frmCstm I have
----------------------------------------------------------------------------------------------
Private Sub Form_Open(Cancel As Integer)
Me.txtUsername = gstrUserName
If Left(Me.OpenArgs, 4) = "Task" Then ' The first part = Task, the rest is the taskID
Me.PageTasks.SetFocus
End If
End Sub
----------------------------------------------------------------------------------------------
So far, so good. The customer form is opened, and the focus is placed on the tab that shows tasks for the customer. However, the focus is always at the top of the Task List. How can I place the focus on the actual taskID that was passed in using OpenArgs?
Many thanks
Ray
Posted by: rayfrew@gmail.com
Reply via web post | • | Reply to sender | • | Reply to group | • | Start a New Topic | • | Messages in this topic (1) |
Tidak ada komentar:
Posting Komentar