Re: Access database not updated when records are deleted

From: Anonymouse (Anonymouse_at_discussions.microsoft.com)
Date: 11/05/04


Date: Fri, 5 Nov 2004 11:20:02 -0800

Okay. I am now officially living in Weirdsville, Microsoftland.

To explain: I looked up OleDbCommandBuilder in Help, and I tried explicitly
creating a Delete command as shown. It STILL didn't work, so I commented it
out and tried single-stepping through the code, trying to figure out what
was/wasn't happening...

...and it worked. THE RECORD I WAS TRYING TO DELETE *WAS* DELETED!

After I'd retrieved my jaw from the floor and glued it back into place, I
decided to test this new, baffling event just to confirm it really WAS
happening and I hadn't lost what remains of my mind. I deleted the database
and replaced it with the unpopulated copy I keep as required by the terms of
my MCAD assignment. I added a few records; no problem. I edited one or two;
all changes were written to the database witthout a hitch. So far so good.

I tried deleting one. It was deleted.

Essentially the code is as it was before I tried creating an explicit Delete
command (although I've discovered that AcceptChanges is indeed unnecessary).
So why the f*** is it working now when it didn't before?! Why is the damn
code now looking back nonchalantly at my baffled face as if to say: 'What?'
?! What IS it with these damn apps?!

Oh well. At least it works now, and I can get on with creating the rest of
the app. Thanks for the help, troops!



Relevant Pages

  • RE: SQL Server slows down when after the apps runs for several hours.
    ... SQL SELECT Optimization Levels and Performance ... >that the longer he use the apps in a day, the longer my apps would take ... I found that the 'command' he referred to is ... General SQL Server question; Anybody got a clue what is the cause? ...
    (microsoft.public.fox.programmer.exchange)
  • VB newbie - exposing VB subs to VBA?
    ... differences of the apps on the two machines, and also that the programs are ... How do I expose VB subs via COM? ... For instance in Excel I ... in on the command line easily enough. ...
    (microsoft.public.vb.com)
  • Cross process communication (sort of)
    ... I have an application which uses several command line utility apps ... One option to accomplish this is to make the manager app an ActiveX ...
    (microsoft.public.vb.general.discussion)
  • Re: where can I find this...
    ... The programs I'm running are very plain apps written in vanilla 'c' code ... When I run these from redcon, ... as if I run them directly from a command prompt. ... Redcon's mechanism of grabbing the stdout pipe doesn't ...
    (borland.public.delphi.nativeapi)
  • Re: Console Applications
    ... Or you open command line first and then execute ... your executable from command line instead of double-clicking it. ... because I want to build Windows apps and not console apps right now? ...
    (microsoft.public.dotnet.languages.csharp)