Results 1 to 2 of 2
  1. #1
    Join Date
    Nov 2013

    Unanswered: Passing parameter between forms


    I have create a Table named as "Student", with 3 fields: ID, stdName, and stdField.

    I also have created a Query named as "stdQuery". This query return the stdField of a given stdName . Using the SQL language, it can be written as:
    Select stdField from Student where stdName = 'John' (for example)

    In the following, I have created a Form named as "studentField". To create this form, I have used "Form wizard" to map the form to "stdQuery". Up to now, everything is fine.

    In the following, I have defined a second form, namely "studentName". This form contains a comboBox which presents the names of the students. I want that when choosing the name of a student in the comboBox, its field is presented in "studentField". Therefore, I have written the following code in the on_click function of the comboBox of "studentName":

    DoCmd.OpenForm "studentField", , , "stdName = " & combo0.selText

    But when selecting a name in "studentName", it asks for a stdName as if I don't pass it to "studentField".

    Cloud anyone please help me about the problem?

  2. #2
    Join Date
    Jun 2005
    Richmond, Virginia USA
    Provided Answers: 19
    Have a look here

    Passing parameter between forms

    where you double-posted the problem.

    Linq ;0)>
    Hope this helps!

    The problem with making anything that fools are so darn ingenious!

    All posts/responses based on Access 2003/2007

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts