Results 1 to 3 of 3
  1. #1
    mgforbes is offline Novice
    Windows 7 64bit Access 2003
    Join Date
    Nov 2013
    Posts
    2

    Question Subform control asking for parameter vaue. Please help.

    Hi guys first post and hoping for some assistance.



    I have a form control (combobox) which displays a list of complaint categorys called [CorrectComplaintCategory] in a form called [QAInput Subform] and another combobox within the same form called [CorrectComplaintCode]

    [CorrectComplaintCategory] has a macro to requery the [CorrectComplaintCode] after update and [CorrectComplaintCode] has the following rowsource:


    Select distinct raw.rng_cc
    From raw
    Where (((raw.rng_cc)<>"Not Found") and ((raw.primary_complaint_tier5_=[forms]![qainput subform]![correctcomplaintcategory]))
    Order by raw.rng_cc;
    This works fine when I have the form open directly, however, if I am using the form as per its intended use (As a subform) then when I select the combobox it asks for the parameter value for [CorrectComplaintCategory] if I manually type in an expected result then it will work.

    My question is how do I get the reference to work when in a subform environment. (The main form is called [Form_Filters])

    Thanks in advance
    Last edited by mgforbes; 11-25-2013 at 02:46 AM. Reason: forgot to include my rowsource

  2. #2
    June7's Avatar
    June7 is online now VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,915
    Give the combobox a name different from the field it is bound to, like: cbxCategory
    Drop the form name qualifier.

    Select distinct raw.rng_cc
    From raw
    Where (((raw.rng_cc)<>"Not Found") and ((raw.primary_complaint_tier5_=[cbxCategory]))
    Order by raw.rng_cc;
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    mgforbes is offline Novice
    Windows 7 64bit Access 2003
    Join Date
    Nov 2013
    Posts
    2
    Hi June

    Thanks for the prompt response. That's worked perfectly, thanks very much.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 10
    Last Post: 02-20-2013, 07:04 AM
  2. Replies: 3
    Last Post: 03-29-2012, 12:40 PM
  3. Use form control value as parameter for query
    By jpkeller55 in forum Access
    Replies: 2
    Last Post: 02-07-2012, 06:09 PM
  4. Hide each control, control group or subform?
    By BRV in forum Programming
    Replies: 2
    Last Post: 12-09-2011, 09:36 AM
  5. Replies: 5
    Last Post: 10-13-2011, 03:36 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums