Results 1 to 2 of 2
  1. #1
    fadiaccess is offline Novice
    Windows XP Access 2003
    Join Date
    Oct 2009
    Posts
    1

    Looping syntax

    Hi Guys,


    I am new in VBA. I need your help cause I am not able to get it.
    What I am trying to accomplish is the following:
    I have 3 sets of check boxes. (Total of 9)

    Set one:
    Checkbox1 name is catname
    Checkbox2 name is cat1
    Checkbox3 name is cat2

    Set two:
    Checkbox1 name is dogname
    Checkbox2 name is dog1
    Checkbox3 name is dog2

    Set three:
    Checkbox1 name is birdname
    Checkbox2 name is bird1
    Checkbox3 name is bird2

    I want to write a code, where if any of the checkbox that ends with "name" are checked, then checkbox that ends with "1" is disabled.
    I am trying to do that in a loop.

    Can you please help.

    Thanks.

  2. #2
    SoftwareMatters is offline Access VBA Developers
    Windows XP Access 2003
    Join Date
    Mar 2009
    Location
    Dorset
    Posts
    274
    I would do this on the Oncurrent of the form and AfterUpdate of the "name" checkboxes. It would be something like this:


    If Me!CatName = Yes then
    Me!Cat1.Enabled = False
    Else
    Me!Cat1.Enabled = True
    End If

    You get the idea.

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

Similar Threads

  1. Replies: 1
    Last Post: 10-07-2009, 07:36 AM
  2. Syntax-reference to pages
    By AmyHill in forum Access
    Replies: 5
    Last Post: 08-27-2009, 10:04 AM
  3. sql syntax error
    By SMAlvarez in forum Access
    Replies: 1
    Last Post: 03-12-2009, 09:43 PM
  4. Hide zero value in report and date syntax
    By Alex Motilal in forum Access
    Replies: 0
    Last Post: 11-16-2008, 09:11 AM
  5. Syntax Error In Insert Into Statement
    By frankvfox in forum Queries
    Replies: 1
    Last Post: 09-09-2008, 12:35 PM

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