melegant Posted May 20, 2003 Posted May 20, 2003 Argh, I have an application with a datagrid in it, and it displays some parts ... so, i crated a routine that after it's deleted it submits the datagrid through the dataadapter to the db..everything is hunky dory.. EXCEPT WHEN I run the applicaiton on any computer that does NOT have vs.studio.net installed on it..then i get an error that says 'deleted row information cannot be accesed through the row.' EVERY other aspect of the app works like a charm on these other machines.. I don't get it..please help ..there are 40 plus people here waiting on this and they are DRIVING ME NUTS!! peace mel Quote
Moderators Robby Posted May 20, 2003 Moderators Posted May 20, 2003 Do they all have the same version of the Framework? Quote Visit...Bassic Software
melegant Posted May 20, 2003 Author Posted May 20, 2003 Yes, 1.1...EVERYTHING else works with the datagrid, updating, adding etc..only when I try to delete the row ): Quote
Moderators Robby Posted May 21, 2003 Moderators Posted May 21, 2003 Did you Run the code in Release Mode on the machine with VS? Quote Visit...Bassic Software
melegant Posted May 21, 2003 Author Posted May 21, 2003 (edited) Yes I have....It has to be something about the number system of the other machines... or mdac maybe? argh i don't know it's killing me. the users are about to stone me to death. Edited May 21, 2003 by melegant Quote
dsgreen57 Posted May 21, 2003 Posted May 21, 2003 I did a quick search on that error message and one common cause is the database ID in the DataGrid doesn't match the ID in the database. Is there any way this could happen due to the way you have set connections up (grasping abit I know) but... or something really does happen with certain data have you tried keying in exactly the same on your machine as the user's machine Quote
melegant Posted May 21, 2003 Author Posted May 21, 2003 Well, I have finally found a pattern but still not a real answer..close now..ever close. A quick bit on the datagrid i have..its a part list , with prices, discounts, descriptions and model #'s. Now, the submit routine i have basically sends grids datasouce, which is a datatable, through the dataadpater as an update and then i refresh the grid. (have to actually set the datasource = nothing first to clear it but anyway) I have discovered that on the machines where it does not work (Row deletion that is) if i first make a change to a field in the datatable and send the update, THEN i can delete rows ok. I am not sure what this means...excepet that i am a step closer! Quote
melegant Posted May 22, 2003 Author Posted May 22, 2003 Eureka! I figured out what the problem was... it's funny when solutions present themselves..i had just gotten home from work, i was preparing to go out to the city , washing my hands thinking about who would be the next american idol, when it hit me... I wasn't calling the sql adapters schema fill method when i loaded the grid.. i called it right before the update (need to to use the command builder) but not on the form load.. and sure enough it worked. i have no idea why it works on my VS pc's without doing this but i suspect it might have something to do with the fact that i have sql server stuff installeD? not sure but hey it worked. the post about the id not matching the primary key clued me in! thanks! mel Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.