Results 1 to 4 of 4
  1. #1
    mrhic
    Guest

    Macro by condition reports. (Access 97)

    Newbie be easy on me : )

    I need to run a macro from a button on a form that prints a serious of reports that grab data from a query that is made up of data from the form. This much is working. I need to be able to condition one ofe the reports to print only if one of the field values = Yes

    Please help me!!!! : )

  2. #2
    3 Star Lounger
    Join Date
    Dec 2000
    Location
    USA
    Posts
    379
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Macro by condition reports. (Access 97)

    Add the conditions column to your macro. You can do this in the macro design window by clicking View/Conditions on the Menu Bar. In the row for that specific report, in the Conditions column, enter something like: [yourFieldValueName] = "Yes". If "Yes" does not evaulate correctly, try [yourFieldValueName] = -1.

  3. #3
    mrhic
    Guest

    Re: Macro by condition reports. (Access 97)

    Am I pointin it to the report, query or form for this field? Like Report! [report name]! [Field name] = -1 ? This is what I have been trying.

  4. #4
    3 Star Lounger
    Join Date
    Dec 2000
    Location
    USA
    Posts
    379
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Macro by condition reports. (Access 97)

    Are you saying that out of all the reports that the macro calls, this particular report should execute only if a value on the form is -1? In that case, use [Forms]![YourFormName]![YourTextboxName]= -1. Remember the form must be open to see the value.
    If you are saying something else, you need to explain the field value that will evaluate to -1and how it relates to the other objects in more detail.

Posting Permissions

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