Results 1 to 1 of 1
  1. #1
    Super Moderator
    Join Date
    Aug 2001
    Evergreen, CO, USA
    Thanked 65 Times in 64 Posts
    I recently had to redesign a table in SQL because we needed to be able to do merge replication. The primary key had been an auto-number table, which causes problems in replication scenarios. I made the change and everything seemed to be happy until I discovered that a report which was being generated from a button on a form displaying a particular record, and using a WHERE condition in the VBA to open the report was issuing a parameter request. I did extensive research and finally concluded that it was a bug, so I created a test database soley in Access, and duplicated the results.

    I then submitted it to Microsoft, and discovered that it was not a bug - I simply wasn't constructing the WHERE clause in the correct manner. Using GUIDs in that situation requires that you use a function called StringFromGUID() in order to get the correct record to display on the report. You can find more about that and other GUID functions from VBA help if you search for GUID.


    Hopefully this will help someone who runs into the same problem - it happens in Access 2002, 2003 and 2007, and in both .mdb and .accdb formats.
    Attached Files Attached Files

Posting Permissions

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