A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Button for Open report by Wizard missing Docmd code.



 
 
Thread Tools Display Modes
  #1  
Old November 17th, 2009, 04:09 PM posted to microsoft.public.access.forms
Hoardling1 via AccessMonster.com
external usenet poster
 
Posts: 24
Default Button for Open report by Wizard missing Docmd code.

Has anyone else encountered this on Access 2007.

In forms
I click on the add button from toolbar and create a button. I use the wizard
and set it to open a report. Go through the process, mainly using defaults.
Once on my form, I expect the button to open my report, but it does nothing.

I checked the VB code and it is missing the Docmd statement, it has the
stDocName = to the report name, but no Docmd statement. Is this an Access
2007 error?? or do I need to turn something on?

--
Message posted via http://www.accessmonster.com

  #2  
Old November 19th, 2009, 04:19 PM posted to microsoft.public.access.forms
tighe
external usenet poster
 
Posts: 53
Default Button for Open report by Wizard missing Docmd code.

Maybe i'm missing something but when using in 2007, the wizard creates an
embedded macro not VBA for the operation. to get Vb you would need to save
the embedded macro then convert. the result would like similar to
DoCmd.openreport "report", acViewReport, "", "", acNormal

also i would figure that stDocName is variable which the conversion would
not create.

"Hoardling1 via AccessMonster.com" wrote:

Has anyone else encountered this on Access 2007.

In forms
I click on the add button from toolbar and create a button. I use the wizard
and set it to open a report. Go through the process, mainly using defaults.
Once on my form, I expect the button to open my report, but it does nothing.

I checked the VB code and it is missing the Docmd statement, it has the
stDocName = to the report name, but no Docmd statement. Is this an Access
2007 error?? or do I need to turn something on?

--
Message posted via http://www.accessmonster.com

.

  #3  
Old November 19th, 2009, 05:06 PM posted to microsoft.public.access.forms
Hoardling1 via AccessMonster.com
external usenet poster
 
Posts: 24
Default Button for Open report by Wizard missing Docmd code.

I didn't create any of the code. I just added the button and used the wizard
to open a report. Which it doesn't. I investigated the code behind the
button and found out there was no docmd process, just setting the variable.
Does it work for you? Add a button and use the wizard to open a report.
Then click button to test.

tighe wrote:
Maybe i'm missing something but when using in 2007, the wizard creates an
embedded macro not VBA for the operation. to get Vb you would need to save
the embedded macro then convert. the result would like similar to
DoCmd.openreport "report", acViewReport, "", "", acNormal

also i would figure that stDocName is variable which the conversion would
not create.

Has anyone else encountered this on Access 2007.

[quoted text clipped - 6 lines]
stDocName = to the report name, but no Docmd statement. Is this an Access
2007 error?? or do I need to turn something on?


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...forms/200911/1

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 11:13 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.