|
|
Our Hot Pick: Rising Antivirus 2006 - Certified by TUV & Checkmark! Get 10% discount by entering this coupon code: ONDISCOUNT10
I have a report that uses a parameter query. The reports lists ProjectName, ProjectType and FiscalYear with the parameter being FiscalYear. I want to add a pie chart to this report in the report footer that shows the various ProjectTypes as a pecentange of all ProjectTypes in a given FiscalYear. The "Enter Parameter Data" dialog box appears several times and when I get through all of those boxes the pie chart doesn't display the data correctly. I found a previous post that suggested creating a separate form dialog box for entering your parameter data to avoid the multiple appearances of the dialog box, which I did, but I get the same results. What am I doing wrong? Thanks, Jim
|
|
Did you replace the parameter in the Record Sources and Row Sources with the reference to the control on the form? Is the form open before you open the report?
-- Duane Hookom MS Access MVP
"JimAA" <JimAA[ at ]discussions.microsoft.com> wrote in message news:E5FEB00B-E825-4551-976F-110F21CE338F[ at ]microsoft.com...
[Quoted Text] >I have a report that uses a parameter query. The reports lists >ProjectName, > ProjectType and FiscalYear with the parameter being FiscalYear. I want to > add a pie chart to this report in the report footer that shows the various > ProjectTypes as a pecentange of all ProjectTypes in a given FiscalYear. > The > "Enter Parameter Data" dialog box appears several times and when I get > through all of those boxes the pie chart doesn't display the data > correctly. > I found a previous post that suggested creating a separate form dialog box > for entering your parameter data to avoid the multiple appearances of the > dialog box, which I did, but I get the same results. What am I doing > wrong? > Thanks, > Jim
|
|
I am a novice Access user so I hope this makes sense. I use the form to open the report. My "Parameter Form" has a combo box to enter the fiscal year. It has a "Cancel" button and an "OK" button. The "OK" button uses the OnClick event which uses Visual Basic's DoCmd.OpenReport, acViewPreview to open the report that shows projects types by a given fiscal year. The report is based on a query that references the combo box of the "Parameter Form" as the Criteria. So I open the "Parameter Form", enter the fiscal year into the combo box, click OK, the report opens showing the selected fiscal year. So far so good. When I move to the next page of the report an "Enter Parameter Value" dialog box appears showing the location of the combo box control and a text box to enter the values. I enter the fiscal year and the report moves to the next page. Same scenario when I move from page to page until I get to the end of the report. I hope you understand what is happening. I am using Access 2003. By the way, I figured out the chart problem. Thanks for your help.
"Duane Hookom" wrote:
[Quoted Text] > Did you replace the parameter in the Record Sources and Row Sources with the > reference to the control on the form? Is the form open before you open the > report? > > -- > Duane Hookom > MS Access MVP > > "JimAA" <JimAA[ at ]discussions.microsoft.com> wrote in message > news:E5FEB00B-E825-4551-976F-110F21CE338F[ at ]microsoft.com... > >I have a report that uses a parameter query. The reports lists > >ProjectName, > > ProjectType and FiscalYear with the parameter being FiscalYear. I want to > > add a pie chart to this report in the report footer that shows the various > > ProjectTypes as a pecentange of all ProjectTypes in a given FiscalYear. > > The > > "Enter Parameter Data" dialog box appears several times and when I get > > through all of those boxes the pie chart doesn't display the data > > correctly. > > I found a previous post that suggested creating a separate form dialog box > > for entering your parameter data to avoid the multiple appearances of the > > dialog box, which I did, but I get the same results. What am I doing > > wrong? > > Thanks, > > Jim > > >
|
|
Do you have any code that closes the "Parameter Form"? It really sounds like when your report opens, the form is closed.
-- Duane Hookom MS Access MVP
"JimAA" <JimAA[ at ]discussions.microsoft.com> wrote in message news:CCFC8833-25F3-4AF7-A88A-ABB6FF599A8D[ at ]microsoft.com...
[Quoted Text] >I am a novice Access user so I hope this makes sense. I use the form to >open > the report. My "Parameter Form" has a combo box to enter the fiscal year. > It > has a "Cancel" button and an "OK" button. The "OK" button uses the > OnClick > event which uses Visual Basic's DoCmd.OpenReport, acViewPreview to open > the > report that shows projects types by a given fiscal year. The report is > based > on a query that references the combo box of the "Parameter Form" as the > Criteria. > So I open the "Parameter Form", enter the fiscal year into the combo box, > click OK, the report opens showing the selected fiscal year. So far so > good. > When I move to the next page of the report an "Enter Parameter Value" > dialog > box appears showing the location of the combo box control and a text box > to > enter the values. I enter the fiscal year and the report moves to the next > page. Same scenario when I move from page to page until I get to the end > of > the report. > I hope you understand what is happening. I am using Access 2003. By the > way, I figured out the chart problem. > Thanks for your help. > > "Duane Hookom" wrote: > >> Did you replace the parameter in the Record Sources and Row Sources with >> the >> reference to the control on the form? Is the form open before you open >> the >> report? >> >> -- >> Duane Hookom >> MS Access MVP >> >> "JimAA" <JimAA[ at ]discussions.microsoft.com> wrote in message >> news:E5FEB00B-E825-4551-976F-110F21CE338F[ at ]microsoft.com... >> >I have a report that uses a parameter query. The reports lists >> >ProjectName, >> > ProjectType and FiscalYear with the parameter being FiscalYear. I want >> > to >> > add a pie chart to this report in the report footer that shows the >> > various >> > ProjectTypes as a pecentange of all ProjectTypes in a given FiscalYear. >> > The >> > "Enter Parameter Data" dialog box appears several times and when I get >> > through all of those boxes the pie chart doesn't display the data >> > correctly. >> > I found a previous post that suggested creating a separate form dialog >> > box >> > for entering your parameter data to avoid the multiple appearances of >> > the >> > dialog box, which I did, but I get the same results. What am I doing >> > wrong? >> > Thanks, >> > Jim >> >> >>
|
|
Thanks! That was the problem. I had "DoCmd.Close acForm" as part of my On Click code. Why do I have to leave the dialog box open? I found that it need to remain open even when printing the report. Just curious.
"Duane Hookom" wrote:
[Quoted Text] > Do you have any code that closes the "Parameter Form"? It really sounds like > when your report opens, the form is closed. > > -- > Duane Hookom > MS Access MVP > > "JimAA" <JimAA[ at ]discussions.microsoft.com> wrote in message > news:CCFC8833-25F3-4AF7-A88A-ABB6FF599A8D[ at ]microsoft.com... > >I am a novice Access user so I hope this makes sense. I use the form to > >open > > the report. My "Parameter Form" has a combo box to enter the fiscal year. > > It > > has a "Cancel" button and an "OK" button. The "OK" button uses the > > OnClick > > event which uses Visual Basic's DoCmd.OpenReport, acViewPreview to open > > the > > report that shows projects types by a given fiscal year. The report is > > based > > on a query that references the combo box of the "Parameter Form" as the > > Criteria. > > So I open the "Parameter Form", enter the fiscal year into the combo box, > > click OK, the report opens showing the selected fiscal year. So far so > > good. > > When I move to the next page of the report an "Enter Parameter Value" > > dialog > > box appears showing the location of the combo box control and a text box > > to > > enter the values. I enter the fiscal year and the report moves to the next > > page. Same scenario when I move from page to page until I get to the end > > of > > the report. > > I hope you understand what is happening. I am using Access 2003. By the > > way, I figured out the chart problem. > > Thanks for your help. > > > > "Duane Hookom" wrote: > > > >> Did you replace the parameter in the Record Sources and Row Sources with > >> the > >> reference to the control on the form? Is the form open before you open > >> the > >> report? > >> > >> -- > >> Duane Hookom > >> MS Access MVP > >> > >> "JimAA" <JimAA[ at ]discussions.microsoft.com> wrote in message > >> news:E5FEB00B-E825-4551-976F-110F21CE338F[ at ]microsoft.com... > >> >I have a report that uses a parameter query. The reports lists > >> >ProjectName, > >> > ProjectType and FiscalYear with the parameter being FiscalYear. I want > >> > to > >> > add a pie chart to this report in the report footer that shows the > >> > various > >> > ProjectTypes as a pecentange of all ProjectTypes in a given FiscalYear. > >> > The > >> > "Enter Parameter Data" dialog box appears several times and when I get > >> > through all of those boxes the pie chart doesn't display the data > >> > correctly. > >> > I found a previous post that suggested creating a separate form dialog > >> > box > >> > for entering your parameter data to avoid the multiple appearances of > >> > the > >> > dialog box, which I did, but I get the same results. What am I doing > >> > wrong? > >> > Thanks, > >> > Jim > >> > >> > >> > > >
|
|
I expect you might have a row source that references the same criteria. You may also have issues if you try to print from the preview window.
-- Duane Hookom MS Access MVP
"JimAA" <JimAA[ at ]discussions.microsoft.com> wrote in message news:9E9B6CCD-F8DB-436D-B9D0-ED4229C568A0[ at ]microsoft.com...
[Quoted Text] > Thanks! That was the problem. I had "DoCmd.Close acForm" as part of my > On > Click code. Why do I have to leave the dialog box open? I found that it > need > to remain open even when printing the report. Just curious. > > > "Duane Hookom" wrote: > >> Do you have any code that closes the "Parameter Form"? It really sounds >> like >> when your report opens, the form is closed. >> >> -- >> Duane Hookom >> MS Access MVP >> >> "JimAA" <JimAA[ at ]discussions.microsoft.com> wrote in message >> news:CCFC8833-25F3-4AF7-A88A-ABB6FF599A8D[ at ]microsoft.com... >> >I am a novice Access user so I hope this makes sense. I use the form to >> >open >> > the report. My "Parameter Form" has a combo box to enter the fiscal >> > year. >> > It >> > has a "Cancel" button and an "OK" button. The "OK" button uses the >> > OnClick >> > event which uses Visual Basic's DoCmd.OpenReport, acViewPreview to open >> > the >> > report that shows projects types by a given fiscal year. The report is >> > based >> > on a query that references the combo box of the "Parameter Form" as the >> > Criteria. >> > So I open the "Parameter Form", enter the fiscal year into the combo >> > box, >> > click OK, the report opens showing the selected fiscal year. So far so >> > good. >> > When I move to the next page of the report an "Enter Parameter Value" >> > dialog >> > box appears showing the location of the combo box control and a text >> > box >> > to >> > enter the values. I enter the fiscal year and the report moves to the >> > next >> > page. Same scenario when I move from page to page until I get to the >> > end >> > of >> > the report. >> > I hope you understand what is happening. I am using Access 2003. By >> > the >> > way, I figured out the chart problem. >> > Thanks for your help. >> > >> > "Duane Hookom" wrote: >> > >> >> Did you replace the parameter in the Record Sources and Row Sources >> >> with >> >> the >> >> reference to the control on the form? Is the form open before you open >> >> the >> >> report? >> >> >> >> -- >> >> Duane Hookom >> >> MS Access MVP >> >> >> >> "JimAA" <JimAA[ at ]discussions.microsoft.com> wrote in message >> >> news:E5FEB00B-E825-4551-976F-110F21CE338F[ at ]microsoft.com... >> >> >I have a report that uses a parameter query. The reports lists >> >> >ProjectName, >> >> > ProjectType and FiscalYear with the parameter being FiscalYear. I >> >> > want >> >> > to >> >> > add a pie chart to this report in the report footer that shows the >> >> > various >> >> > ProjectTypes as a pecentange of all ProjectTypes in a given >> >> > FiscalYear. >> >> > The >> >> > "Enter Parameter Data" dialog box appears several times and when I >> >> > get >> >> > through all of those boxes the pie chart doesn't display the data >> >> > correctly. >> >> > I found a previous post that suggested creating a separate form >> >> > dialog >> >> > box >> >> > for entering your parameter data to avoid the multiple appearances >> >> > of >> >> > the >> >> > dialog box, which I did, but I get the same results. What am I >> >> > doing >> >> > wrong? >> >> > Thanks, >> >> > Jim >> >> >> >> >> >> >> >> >>
|
|
|