|
|
I have an 2003 access database that works fine on Windows XP, but errors out on the docmd.openform line of code (OpenForm action was cancelled) after upgrading to Vista. Strangely enough, this is only a problem for one form, so far. All the other forms that have identical code work fine. Basically, I have the user select a record from a subform and then click on a command button (which rebuilds the query for another form, saves it, and then opens the form to allow editing of the selected record).
Here's the code: DoCmd.OpenForm "frmNameOfForm", , , , , , "Edit"
Thanks for your help.
|
|
hi,
Crossh wrote:
[Quoted Text] > I have an 2003 access database that works fine on Windows XP, but errors out > on the docmd.openform line of code (OpenForm action was cancelled) after > upgrading to Vista. Strangely enough, this is only a problem for one form, so > far.
Sounds like corruption. Create a new .mdb, import all your objects (tables, queries, forms etc.)...
mfG --> stefan <--
|
|
Thanks, but I don't think that's the issue. It only happens when the user with Vista runs the code. The database works fine for everyone else (using Windows XP). I have already sent the Vista user new copies of the working database, and it still errors out on that line of code. Maybe I should mention that it's an Acces front-end with SQL Server 2005 on the backend. Any other ideas?
"Stefan Hoffmann" wrote:
[Quoted Text] > hi, > > Crossh wrote: > > I have an 2003 access database that works fine on Windows XP, but errors out > > on the docmd.openform line of code (OpenForm action was cancelled) after > > upgrading to Vista. Strangely enough, this is only a problem for one form, so > > far. > Sounds like corruption. Create a new .mdb, import all your objects > (tables, queries, forms etc.)... > > > mfG > --> stefan <-- >
|
|
hi,
Crossh wrote:
[Quoted Text] > Thanks, but I don't think that's the issue. It only happens when the user > with Vista runs the code. The database works fine for everyone else (using > Windows XP). I have already sent the Vista user new copies of the working > database, and it still errors out on that line of code. Maybe I should > mention that it's an Acces front-end with SQL Server 2005 on the backend. Any > other ideas?
Timeout due to lock escalation? What does your code when this form is opened?
mfG --> stefan <--
|
|
I have the user select a record from a subform, click on a command button on the main form. The command button rebuilds the query for the new form that I want it to open, saves the new query, and then opens the new form (which uses the query as the record source) to allow editing of the selected record. The subform is a pass thru query with no locks.
Again, this is ONLY an issue using VISTA. I have had users running these forms for over a year without ever having any problems. This one user upgraded to Vista, and now he has this problem. All other Windows XP users run fine.
I have another form/subform in this database, which is identical in logic, except that is refences another query. This form works fine for the Vista user.
Thanks for your help.
"Stefan Hoffmann" wrote:
[Quoted Text] > hi, > Timeout due to lock escalation? What does your code when this form is > opened? > > mfG > --> stefan <-- >
|
|
hi,
Crossh wrote:
[Quoted Text] > Again, this is ONLY an issue using VISTA. I have had users running these > forms for over a year without ever having any problems. This one user > upgraded to Vista, and now he has this problem. All other Windows XP users > run fine.
Drop any error handler, maybe this will reveal someting. Basic question: does this user run the same Office, same Service Pack, same Jet/MDAC? Does he run this database from a local drive? Has he sufficent rights for this location?
mfG --> stefan <--
|
|
I have the error handler commented out, that's how I know which line is causing the error. This user has a new laptop, which is why he has Vista. I'm sure nothing is the same, the rest of us have Windows XP. But how would that explain two forms in this same database, with the same code, operating differently? One works fine and the other errors out only on the docmd.openform line of code. Both forms are using ODBC links to the same SQL Server db. He can edit the record while in the raw data, just can't open the one form.
"Stefan Hoffmann" wrote:
[Quoted Text] > hi, > Drop any error handler, maybe this will reveal someting. Basic question: > does this user run the same Office, same Service Pack, same Jet/MDAC? > Does he run this database from a local drive? Has he sufficent rights > for this location? > > > mfG > --> stefan <-- >
|
|
"Crossh" <Crossh[ at ]discussions.microsoft.com> wrote in message news:A820130E-C489-4E28-AEE7-7C6F28CC2311[ at ]microsoft.com...
[Quoted Text] >I have the error handler commented out, that's how I know which line is > causing the error. This user has a new laptop, which is why he has Vista. > I'm > sure nothing is the same, the rest of us have Windows XP. But how would > that > explain two forms in this same database, with the same code, operating > differently? One works fine and the other errors out only on the > docmd.openform line of code. Both forms are using ODBC links to the same > SQL > Server db. He can edit the record while in the raw data, just can't open > the > one form.
PMFJI, but I doubt it's the OpenForm action itself. But if there's something about the form being opened that prevents it from being opened, it will have the same effect. Can that form be opened by double-clicking it, directly from the database window? Can the form's recordsource be opened directly? Is there any code in the form's Open event that might be causing an error?
-- Dirk Goldgar, MS Access MVP www.datagnostics.com
(please reply to the newsgroup)
|
|
What does PMFJI mean? Yes, the form can be opened by double-clicking from the database window. Yes, the form's recordsource can be opened directly. There's plenty of code, but wouldn't that be a problem when opening directly, too?
"Dirk Goldgar" wrote:
[Quoted Text] > PMFJI, but I doubt it's the OpenForm action itself. But if there's > something about the form being opened that prevents it from being opened, it > will have the same effect. Can that form be opened by double-clicking it, > directly from the database window? Can the form's recordsource be opened > directly? Is there any code in the form's Open event that might be causing > an error? > > -- > Dirk Goldgar, MS Access MVP > www.datagnostics.com > > (please reply to the newsgroup) > >
|
|
"Crossh" <Crossh[ at ]discussions.microsoft.com> wrote in message news:70233BDA-FF45-47E2-AF92-295B4413BC07[ at ]microsoft.com...
[Quoted Text] > What does PMFJI mean?
"Pardon me for jumping in".
> Yes, the form can be opened by double-clicking from the > database window. Yes, the form's recordsource can be opened directly. > There's > plenty of code, but wouldn't that be a problem when opening directly, too?
Yes, normally. Hmm ... I notice that your OpenForm line is passing a value via the OpenArgs argument. Maybe the code to process that argument is causing an error. Try executing that exact line from the Immediate window, and see what happens.
-- Dirk Goldgar, MS Access MVP www.datagnostics.com
(please reply to the newsgroup)
|
|
I just found the culprit. Apparently Vista dosn't like to filter the dates in the db. The query has a date filter in it. If I go into any table and try to filter any date (just by clicking on the the Filter By Selection button) I get the message, "Microsoft Access has stopped working" and it closes the db down. I have installed all the latest updates for Vista and Office. Now what?
"Dirk Goldgar" wrote:
[Quoted Text] > Yes, normally. Hmm ... I notice that your OpenForm line is passing a value > via the OpenArgs argument. Maybe the code to process that argument is > causing an error. Try executing that exact line from the Immediate window, > and see what happens. > > -- > Dirk Goldgar, MS Access MVP > www.datagnostics.com > > (please reply to the newsgroup) > >
|
|
"Crossh" <Crossh[ at ]discussions.microsoft.com> wrote in message news:CC5C09E1-E4DC-4311-A4E0-EAA79F88808B[ at ]microsoft.com...
[Quoted Text] >I just found the culprit. Apparently Vista dosn't like to filter the dates >in > the db. The query has a date filter in it. If I go into any table and try > to > filter any date (just by clicking on the the Filter By Selection button) I > get the message, "Microsoft Access has stopped working" and it closes the > db > down. I have installed all the latest updates for Vista and Office. Now > what?
It seems unlikely that it's a Vista problem. Did you only upgrade your OS, or did you upgrade to Access 2007 at the same time? Did you actually upgrade your OS and/or copy of MS Office, or are you switching your database between different PCs with different versions installed?
-- Dirk Goldgar, MS Access MVP www.datagnostics.com
(please reply to the newsgroup)
|
|
hi,
Crossh wrote:
[Quoted Text] > I just found the culprit. Apparently Vista dosn't like to filter the dates in > the db. The query has a date filter in it.
Post that query. Maybe its a localization problem.
http://allenbrowne.com/ser-36.html
mfG --> stefan <--
|
|
I could, but it's not not the query, it has something to do with trying to filter the date. When I go into any ODBC linked (SQL 2005) table and try to filter any date (just by clicking on the the Filter By Selection button) I get the error message, "Microsoft Access has stopped working" and it closes the db down. Apparently Vista doesn't like SQL Server dates?
"Stefan Hoffmann" wrote:
[Quoted Text] > hi, > > Crossh wrote: > > I just found the culprit. Apparently Vista dosn't like to filter the dates in > > the db. The query has a date filter in it. > Post that query. Maybe its a localization problem. > > http://allenbrowne.com/ser-36.html> > > mfG > --> stefan <-- >
|
|
|