Results 1 to 2 of 2
  1. #1
    2 Star Lounger
    Join Date
    Jun 2002
    Posts
    114
    Thanks
    0
    Thanked 0 Times in 0 Posts

    if Clause (Access 2000)

    I need a help with an If Clause. i have three contradicting conditions and the results are not always stisfactory.
    The conditions are :

    If IsNull(Me![Customerid]) = True Then
    If Me![ChkStorehouse] = False Or Me!ChkWarehouse = False Then
    dosomething

    I wil explain what i want to do:
    1. The entire code must work only when Customerid is not null
    2. the code DoSomething must not work if
    ChkSotreshouse = True
    or ChkWarehouse = True

  2. #2
    4 Star Lounger SteveH's Avatar
    Join Date
    Jan 2001
    Location
    Chelsea, Gtr London, United Kingdom
    Posts
    587
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: if Clause (Access 2000)

    Does this air-code do it?
    <pre>If Not IsNull(Me![Customerid]) Then
    If Me![ChkStorehouse] = False And Me!ChkWarehouse = False Then
    DoSomething
    Else
    'Do Nothing
    End If
    Else
    'Customer ID is Null so do nothing
    End If
    </pre>

    Steve H
    IT Lecturer/Access Developer
    O2K SR3/O2010; Win7Pro

Posting Permissions

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