PDA

Click to See Complete Forum and Search --> : Why isn't my recordset refreshing


rogergho
Jan 18th, 2002, 05:14 PM
Hi guys, here's the problem i'm facing
I'm testing my application that uses an Access 2000 database.
Here's the Connection parameters :
RsEmployee.CursorLocation = adUseClient
RsEmployee.CursorType = adOpenDynamic
RsEmployee.LockType = adLockOptimistic

There is actually 2 forms thats uses the same recordset and considering the fact that i don't want to use a public recordset i opened the same table twice in the 2 forms. (with # recordset names)
The strange thing is that when i UPDATE a recordset i don't see the changes in the 2nd one unless i do the REQUERY method. Is that normal ? Isn't the adOpenDynamic parameter supposed to resolve this problem ?

Here is a sample of my application :
I have an MDIForm, meaning that you really don't know what form is going to be fired. So The invoice form has a recordset for the item table and the Stock form has a recordset to the item table.
When the user minimizes the invoice form, go to the stock form, add an item, i must be able to see it in the invoice form when i browse my recordset.
It's not logic to issue a requery method in the activate event of the invoice form, so what do you think ?

Thanks for your help.

oddprime
Jan 23rd, 2002, 09:26 AM
When you actually open your recordset you cursors are going to change.

keep those settings

CursorLocation
CursorType
LockType

like you have them.
Then open your recordset and go back and
check those three items out.

you will find that they have changed.

There are only certing CursorTypes and LockTypes that you can open with a ClientCursor, and same only certin locktypes and cursorTypes you can open with a server location..


Also if you are trying to USE a client cursor, how do you expect to see updates from the server? ????

If you wanna see updates from the server your going to need to keep the cursor on the server.