Access/SQL: record saves when I run macro or code (1 Viewer)

DocNice

Registered User.
Local time
Yesterday, 21:10
Joined
Oct 6, 2004
Messages
76
I am running an Access interface to a SQL server. When I run a macro or code, the form saves the current record and moves to a new line.

Any idea why this is happening or how to work around it?
 

IgorB

Registered User.
Local time
Today, 05:10
Joined
Jun 4, 2003
Messages
183
I created your problem manually and can confirm that if you go in database to menu "Tools--Options---Keyboard", you probably have setting "Next record". You better of to change it to "Next field".
It works perfect for me.

Good luck.
Igor.
 

DocNice

Registered User.
Local time
Yesterday, 21:10
Joined
Oct 6, 2004
Messages
76
IgorB,
Thanks for the suggestion. I found some other things in there that help me, but it still doesn't fix this problem. I think it's to do with SQL, because it seems to work fine with Access tables.
 

Pat Hartman

Super Moderator
Staff member
Local time
Today, 00:10
Joined
Feb 19, 2002
Messages
43,774
When I run a macro or code, the form saves the current record and moves to a new line.
What code are you running? Code that requeries the recordset for example, will automatically save the current record. In an .mdb there is no difference in when a record is saved when the be is SQL server rather than Jet. The only difference is when the autonumber is assigned. With Jet, you see the assigned autonumber as soon as you enter data into any field. With a RDBMS be, you won't see the assigned autonumber until the record is actually committed (saved).
 

DocNice

Registered User.
Local time
Yesterday, 21:10
Joined
Oct 6, 2004
Messages
76
You're right it's not SQL. I thought it was, because all of this was working right before I moved the tables to SQL, and with the autonumber being assigned at the end, I thought it was another change like that. In the interests of being thorough, I have done quite a bit of troubleshooting and have ruled that out, as well as running macros, though I still haven't found the source yet.

Thanks for your help. I'm sure I"ll get it.
 

Users who are viewing this thread

Top Bottom