Results 1 to 3 of 3
  1. #1
    dmenger is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Mar 2014
    Posts
    3

    Set Control Property for Continuous form based on value in that record


    Hi all,
    I should be able to do this but can't find the solution.

    Using Access 2013

    I have a continuous subform based that is has a parent child link to the main form.
    In the sub form I want to put a button that only shows based on a value for that record in the sub form.
    Right now I can only get this to recognize the first record, but I need this to be dynamic for each record.

  2. #2
    burrina's Avatar
    burrina is offline VIP
    Windows 8 Access 2010 32bit
    Join Date
    Oct 2012
    Location
    Freeport,Texas
    Posts
    1,383
    I suspect you are placing the command button on each record. I would place it on the form header or form footer and then use the OnGotFocusEvent to fire your code.

    HTH

  3. #3
    ssanfu is offline Master of Nothing
    Windows XP Access 2000
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    I agree with burrina. The button should be placed in the sub form header. But I would use the subform current event. Each time you change records in the sub form, the On Current event fires.

    I don't like having objects appear and disappear unless absolutely necessary/required, so I would use the Enabled property of the button.

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

Similar Threads

  1. Replies: 2
    Last Post: 09-24-2014, 05:19 PM
  2. Replies: 8
    Last Post: 05-23-2014, 02:19 PM
  3. Replies: 2
    Last Post: 01-01-2014, 02:10 PM
  4. Calculated control on Continuous Form
    By Mtyetti2 in forum Forms
    Replies: 2
    Last Post: 03-25-2013, 05:13 PM
  5. Record Count based on Form control value
    By Monterey_Manzer in forum Forms
    Replies: 7
    Last Post: 11-29-2012, 10:47 AM

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