Go Back   Access World Forums > Microsoft Access Discussion > Forms

 
Reply
 
Thread Tools Rate Thread Display Modes
Old 09-10-2019, 08:40 AM   #16
theDBguy
Iím here to help
 
theDBguy's Avatar
 
Join Date: Oct 2018
Location: SunnySandyEggo
Posts: 4,146
Thanks: 46
Thanked 971 Times in 952 Posts
theDBguy will become famous soon enough theDBguy will become famous soon enough
Re: Complex query - readonly recordset workaround

Quote:
Originally Posted by Pat Hartman View Post
Your code isn't working because the openForm code is run before the active form actually closes. Do what I suggested and use two forms.
Hi Matt. I agree with Pat. It's better if you use two separate forms like I was saying earlier.

__________________
Just my 2 cents...

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
theDBguy is online now   Reply With Quote
Old 09-10-2019, 08:47 AM   #17
matt beamish
Newly Registered User
 
Join Date: Sep 2000
Location: Leicester, UK
Posts: 180
Thanks: 18
Thanked 1 Time in 1 Post
matt beamish is on a distinguished road
Re: Complex query - readonly recordset workaround

Ah thanks for replies, yes I will try a separate form on a pop up. DBGuy - sorry for "it isn't working" as I appreciate that that is so useless (although Pat understood...). No there is no error, the form simply opens as it would otherwise do according to the arguments built into 'On Open'.
thanks folks.
PS Why doesn't DoCmd.Close happen before DoCmd.Open when it is told to do that?
matt beamish is offline   Reply With Quote
Old 09-10-2019, 09:03 AM   #18
theDBguy
Iím here to help
 
theDBguy's Avatar
 
Join Date: Oct 2018
Location: SunnySandyEggo
Posts: 4,146
Thanks: 46
Thanked 971 Times in 952 Posts
theDBguy will become famous soon enough theDBguy will become famous soon enough
Re: Complex query - readonly recordset workaround

Quote:
Originally Posted by matt beamish View Post
Ah thanks for replies, yes I will try a separate form on a pop up. DBGuy - sorry for "it isn't working" as I appreciate that that is so useless (although Pat understood...). No there is no error, the form simply opens as it would otherwise do according to the arguments built into 'On Open'.
thanks folks.
PS Why doesn't DoCmd.Close happen before DoCmd.Open when it is told to do that?
Well, Pat is one of the smartest people around here. I still have a long ways to go. Good luck and let us know how it goes.

__________________
Just my 2 cents...

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
|
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
theDBguy is online now   Reply With Quote
Old 09-11-2019, 02:16 PM   #19
Pat Hartman
Super Moderator
 
Join Date: Feb 2002
Location: Stratford,Ct USA
Posts: 27,988
Thanks: 13
Thanked 1,539 Times in 1,464 Posts
Pat Hartman is a name known to all Pat Hartman is a name known to all Pat Hartman is a name known to all Pat Hartman is a name known to all Pat Hartman is a name known to all Pat Hartman is a name known to all
Re: Complex query - readonly recordset workaround

Quote:
Well, Pat is one of the smartest people around here.
??? I've just made more mistakes than all of you put together. My curse is that I remember them but my gift is that I frequently remember the solution also.

Quote:
PS Why doesn't DoCmd.Close happen before DoCmd.Open when it is told to do that?
Because the form can't close until the code module finishes executing. If it did, it would never execute the open command so you'd still be wondering why it didn't work

__________________
Bridge Players Still Know All the Tricks
Pat Hartman is offline   Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Alternative or workaround to using LIKE in query trstorer Queries 3 04-17-2017 05:13 AM
Query is read-only, need workaround help fluid Queries 12 01-19-2017 05:31 PM
Workaround SharePoint Query Limit? nickbarnes Modules & VBA 5 08-29-2011 06:02 AM
Result of subquery based on Snapshot query is not readonly Guus2005 Queries 2 04-24-2008 06:26 AM
Need Readonly query output ashishprem Modules & VBA 6 03-22-2008 08:10 AM




All times are GMT -8. The time now is 09:55 PM.


Microsoft Access Help
General
Tables
Queries
Forms
Reports
Macros
Modules & VBA
Theory & Practice
Access FAQs
Code Repository
Sample Databases
Video Tutorials

Featured Forum post


Sponsored Links


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
(c) copyright 2017 Access World