[AccessD] Binding form/subform to ADO recordset

StaRKeY starkey at wanadoo.nl
Wed Jul 14 15:20:34 CDT 2004


Hi all,
 
I am still working on my ADP and slowly moving on to ADO wisdom:-)
However I've run into the following situation and I hope someone knows the
solution...
 
Situation:
A2K3 - ADP - SQL server 2000
Two forms, Main and sub (datasheet) on main, relation one-to-many
 
The Mainform as well as the subForm get bound on the 'OnOpen' event of the
mainform using ADO recordsets which are closed and set to nothing once bound
to the form/datasheet. 
This works great.. editing records no problem BUT adding a new record to the
sub datasheet results in an error:
 
"Key value for this row was changed or deleted at the datastore. The local
row is now deleted" 
 
I have been snooping the internet and I should probably make somehow use of
the 'Uniquetable' property and the 'Resync Command' but does anybody know
how and where? (form or code or both, what event?)
I've seen code from MS
(http://support.microsoft.com/default.aspx?scid=http://support.microsoft.com
:80/support/kb/articles/Q251/0/21.ASP
<http://support.microsoft.com/default.aspx?scid=http://support.microsoft.com
:80/support/kb/articles/Q251/0/21.ASP&NoWebContent=1> &NoWebContent=1) which
uses a recordset addnew - update though my records are bound to this
datasheet and my recordset is long gone... now I wonder if I'll be able to
get this to work?
 
Tia,
Eric Starkenburg


  _____  


avast! Antivirus <http://www.avast.com> : Uitgaande bericht is niet besmet. 


Virus Gegevensbestand (VPS): 0429-0, 12-07-2004
Getest op: 14-7-2004 22:20:34
avast! auteursrecht (c) 2000-2004 ALWIL Software.





More information about the AccessD mailing list