Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Corrupt db - Click checkbox and application crashes

Status
Not open for further replies.

LeanneGodney

Technical User
Mar 7, 2002
175
GB
Hi guys,

I'm hoping someone can help me out here. I've been working on a particular form for a few days now making changes to the how the form grabs the data. I've been changing it to be disconnected - a public adodb.recordset that feeds the form. This has all been working a charm until about four hours ago!

Now, whenever I click a checkbox the db crashes. I can change any other data, but whenever it's a checkbox that is clicked it crashes...

Pretty please, if anyone knows why this is happening and how I can stop it, PLEASE let me know...

Thanks,
Leanne
 
Did you search the web for the answer, first? Did you search this site?

I ask because it almost seems a shame to so quickly up and tell you how to work around it, just like that, no pain and all, bam. Seeing as it took me weeks and weeks to come up with the solution... and seeing as I posted about it and no one even bothered to reply... it'd be irksome if you didn't at least try a little on your own.
 
Hi there,

Actually I didn't really know what to search for! Have found it quite difficult looking for previous posts on things I've needed help with in the past as I never seem to use the right words to search. Usually I do though. THis time I have been working on a very tight deadline of other stuff, so was hopeful that perhaps someone may have had this same problem.

Sorry to sound lazy, but circumstance simply dictated it this time...

If you dont' want to help could you please let me know what phrase to search the net for?

Leanne
 
There are a lot of small tricks you'll get more familiar with as you start to grow accustomed to this site. One hint here, is that ESquared says they have posted about it - click their handle to enter their profile, try to figure out the most likely forum for which they have posted this ADP-related reply (hit the "total replies" number for that forum), then try figuring out which thread it might be (a hint - it's got something to do with hair colour).

For searches, hmmm - what might be relevant terms. I'd guess the datatype of the field the checkbox is bound to is relevant, together with checkbox?

Roy-Vidar
 
THanks Roy! I found the thread. I was searching for checkbox crash adp - didn't even think to search for the data type... You learn new things each day. :0) Will read ESquared's post tomorrow when I get to work. Thanks for your help!

Leanne
 
Just for anyone else who may have this problem...

I can't use the fix above from ESquared for every checkbox that is causing my application to crash. The way I'm getting around it is this.

I have a disconnected recordset feeding my form, so it's not linking directly to my table. I have created another checkbox that is unbound. When the user clicks it it fires off an on_click event that sets the disconnected recordset's value to true or false depending on what they've done. Then the user has to click the save button in order to save these changes.

I've found that if your on_click event sets the original field to true or false then you still crash, which is why I get it to set the value of the disconnected recordset instead. So it would appear this is a fault with FORMS in ADPs rather than the link to the data.

If anyone needs more help on this, or code examples, then post a reply and I'll give more detail.

Leanne
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top