Page 2 of 2 FirstFirst 12
Results 16 to 22 of 22
  1. #16
    mejia.j88 is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    Nov 2011
    Location
    california
    Posts
    228
    upon running the query, #Error is shown in the column End_of_lot (i changed it from End to avoid trouble),



    one question: what exactly is the last part of the sql that says As EndOfLot?

  2. #17
    Robeen is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    Mar 2011
    Location
    Tulsa, Oklahoma.
    Posts
    1,596
    'EndOfLot' is the new name I gave to the Column that has the "Yes" or "No". I'm saying give me the data from that column in the table and name the column header 'EndOfLot'.
    You can call it whatever you want - but not the same name as the field itself [Access will tell you there is a 'circular reference'].

    In your Label Report - go to the field that is giving you that error - right-click and go to Properties.
    Click the 'Data' Tab.
    From the Drop Down in the 'Control Source' row - select your 'EndOfLot' field [or whatever you decide to name it].

    Now - run your report and make sure it is working.

    If the report is not working . . . is your Query itself running? On its own?

  3. #18
    mejia.j88 is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    Nov 2011
    Location
    california
    Posts
    228
    the #error is in the query under the column EndOfLot when i view it in datasheet view.

    thanks,

  4. #19
    Robeen is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    Mar 2011
    Location
    Tulsa, Oklahoma.
    Posts
    1,596
    hmm . . . this usually means that there is a data-type mismatch . . .
    You have a Boolean [True/False] field and I am trying to force a String into there.

    Ok - try this:
    Take the IIF statement off your End_Of_Lot field.
    Put it back to just the actual field name.

    Now - create a new field to the right and put something like this in there:
    EndOfLot_Text: IIF(End_Of_Lot = 0, "Yes", "No")

    Where I had:
    End_Of_Lot = 0
    make sure you have the name of your actual end-of-lot field.

    then you'll have to point your report to the new field you created.

    Hope this works!

  5. #20
    RayMilhon is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    Aug 2011
    Location
    Southern California
    Posts
    1,067
    In the report in the textbox where it is displaying the -1,0 change the control source to =IIF([myend],"Yes","False") Sorry but I just can't use reserved words as field names.

  6. #21
    mejia.j88 is offline Competent Performer
    Windows 7 32bit Access 2007
    Join Date
    Nov 2011
    Location
    california
    Posts
    228
    Thank you all so much for your help!

  7. #22
    Robeen is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    Mar 2011
    Location
    Tulsa, Oklahoma.
    Posts
    1,596
    Which solution did you end up using?

    I liked Ray's suggestion. It seemed a lot more direct and simple than what I was suggesting! I wish I had thought of approaching it that way!

Page 2 of 2 FirstFirst 12
Please reply to this thread with any new information or opinions.

Similar Threads

  1. Simple QBE
    By MikeDBMan in forum Queries
    Replies: 6
    Last Post: 08-31-2011, 02:37 PM
  2. Need some help with simple VBA Thanks
    By everette in forum Programming
    Replies: 1
    Last Post: 08-07-2011, 08:32 AM
  3. Hopefully simple If Then
    By fender357 in forum Programming
    Replies: 4
    Last Post: 05-09-2011, 07:52 PM
  4. Replies: 0
    Last Post: 10-21-2010, 08:24 AM
  5. Simple Export Not So Simple
    By jgelpi16 in forum Programming
    Replies: 11
    Last Post: 09-01-2010, 07:23 AM

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