Where am I going wrong and why can't I write to a record that I locked?
Please help. This is driving me crazy!
Thanks.
Doug
Bye, Olaf.
I have a form with a combo box with the rowsource property set to a sql
statement:
SELECT * FROM importer INTO CURSOR invImporter ORDER BY ImporterName WHER
!notcurrentimporter AND !importerarchived
Then I call another form from this form which has an edit box on it. I had
the controlsource property of the edit box set to
'invImporter.importerinvoicenotes'. This is what I had last night when I
posted this message. After I posted it I figured that the problem was using
the field name from a sql file into the controlsource of another field.
Then I tried creating a new sql statement in the second form that's exactly
like the other sql except creating a different cursor name. This actually
worked which I can use but I'm now looking for a simpler solution.
What I tried next was to set the Value property of the second form's edit
box with invImporter.importerinvoicenotes but I get the "Attempting to lock
..." message again. I don't know why this doesn't work. Any ideas?
Doug
"Olaf Doschke" <b2xhZi5kb3NjaGt...@strconv.14.de> wrote in
message news:eupvJBL...@TK2MSFTNGP04.phx.gbl...
An SQL does create a readonly cursor if not specified otherwise.
That maybe one root of your problem.
> What I tried next was to set the Value property of the second form's edit
> box with invImporter.importerinvoicenotes but I get the "Attempting to
> lock ..." message again. I don't know why this doesn't work. Any ideas?
If the Editbox isn't set Readonly and has a controlsource set setting focus
to
it will try writing to the controlsource.
Setting the value should work, as soon as you unset the Editboxs
controlsource,
because then the only thing you'll edit is the Editbox.Value but not any
field of any controlsource.
AS you don't specify what the controlsource of the other forms editbox is,
this might be the thing to look at, but I'd search for even another third
source of the "attempting to lock" message. A lock attempt is made at
writing, not at reading.
Bye, Olaf.
Doug
"Olaf Doschke" <b2xhZi5kb3NjaGt...@strconv.14.de> wrote in
message news:%23FSwV6W...@TK2MSFTNGP06.phx.gbl...