[mso] opening a new form based on a field in a previous form
- From: Leeba <leebaf@xxxxxxxxxx>
- To: MS_Access_Professionals@xxxxxxxxxxxxxxx, mso@xxxxxxxxxxxxx
- Date: Mon, 11 Feb 2008 09:46:55 +0200
I have a form with a list of clients. There is a combo box with a list of
projects for each client or an option to add a new project.
When clicking a new project, it should automatically fill in the client ID
to match the clientID on the previous form.
My code is:
Private Sub Command34_Click()
On Error GoTo Err_Command34_Click
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "projects"
stLinkCriteria = "[ClientID]=" & Me![ClientID]
DoCmd.OpenForm stDocName, , , stLinkCriteria
Exit_Command34_Click:
Exit Sub
Err_Command34_Click:
MsgBox Err.Description
Resume Exit_Command34_Click
End Sub
This is not working. Anyone figure out why.
TIA,
Leeba
*************************************************************
You are receiving this mail because you subscribed to mso@xxxxxxxxxxxxx or
MicrosoftOffice@xxxxxxxxxxxxxxxx
To send mail to the group, simply address it to mso@xxxxxxxxxxxxx
To Unsubscribe from this group, visit the group's homepage and use the dropdown
menu at the top. This will allow you to unsubscribe your email address or
change your email settings to digest or vacation (no mail).
http://www.freelists.org/webpage/mso
To be able to share files with the group, you must join our Yahoo sister group.
This group will not allow for posting of emails, but will allow you to join
and share problem files, templates, etc.:
http://tech.groups.yahoo.com/group/MicrosoftOffice . This group is for FILE
SHARING ONLY.
If you are using Outlook and you see a lot of unnecessary code in your email
messages, read these instructions that explain why and how to fix it:
http://personal-computer-tutor.com/abc3/v28/greg28.htm
*************************************************************
- Follow-Ups:
- [mso] Re: opening a new form based on a field in a previous form
- From: Dian D. Chapman
Other related posts:
- » [mso] opening a new form based on a field in a previous form
- » [mso] Re: opening a new form based on a field in a previous form
- » [mso] Re: opening a new form based on a field in a previous form
- » [mso] Re: opening a new form based on a field in a previous form
- [mso] Re: opening a new form based on a field in a previous form
- From: Dian D. Chapman