Monday 4 August 2008

I think this is called a "bug"


While swearing violently at Access 2007, I discovered that one of the problems doomed to make my day a misery was that after walking through the nice, automated, hand-holding steps to create a button which would open the item currently displayed in form "Show Item" in form "Edit Item", the resultant button would do no such thing. It would open "Edit Item" correctly, but it would open it at default, at item 1. Which only works correctly for one item, which isn't particularly useful when you're expecting the database to hold several hundred.

So eventually I gave up on Google, took a deep breath and dived into the code. I am not a programmer. I do not know VBA, I do not know SQL. Given statements in either of those languages I could, maybe, figure out their intent. But don't bet on it.

Eventually, however, I resorted to Microsoft Help and put the cursor in the "Where Condition" box in the Macro Tools page, and hit F1.

I was told that in order to do what I was trying to do I would have to enter a statement which, after dropping in the right values, looked like this:

[ID]=[Forms]![Show Item]![ID]

The problem being that the statement which Access had decided, after asking me what I wanted to do, to put into the code attached to the button in question ooked like this:

"[ID]=" & [ID]

Now I may just be a simple hyper-chicken, but they look different to me. There is a distinct air of difference about them, of not being the same. And I have a sneaking suspicion that computers care about exactness. That they don't actually work if the address you give it is "Oh, down from the corner with the fig tree on it, and on that side of the S-bend, you know."

Microsoft, you have fucked up.

Again.

No comments:

Search This Blog