-
Mar 28th, 2010, 08:50 PM
#1
Thread Starter
New Member
Help with Code to open a form at specific record.....HELP HELP
hi
i'm not expert in writting vb codes.
but there's this IT project im doing in access i need help with i'll be very thankfull.
I don't know if my code is fine i have just been learning from different site and came up with this code.
.
.
.
Basically i have this database which stores customer details in frm_customers but then the problem is that i have this button called "view/edit customer" what i want it to do is that when i click this button an input box pop ups and asks user for a customer ID he wants to go to, then it opens frm_customers to that specific record using CustomerID. i have these codes stated below but they are not working:
Private Sub Command105_Click()
Dim stDocName As String
Dim stCustomerId As String
stDocName = "frm_customers"
stCustomerId = InputBox "Enter Customer Id you want to go to?", "Customer Search"
DoCmd.openform = stDocname
DoCmd.GoToRecord stCustomerId
End Sub
Help me please.
Thankyou Very Much!
-
Mar 29th, 2010, 03:24 AM
#2
Re: Help with Code to open a form at specific record.....HELP HELP
Thread moved to 'Office Development/VBA' forum... note that while it certainly isn't made clear, the "VB Editor" in Office programs is actually VBA rather than VB, so the 'VB6' forum is not really apt
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
|