Re:Report Preview
Okay - I misread your post. I do not think you should give them the option
to print the report after closing the preview window. It's an extra
unnessary step and if you think about it, all standard windows apps such as
Microsoft Word, or any other do not have a prompt to print after closing a
preview window. So, I would say to take that prompt out. Allow them to
print or preview first and then they can print in the preview if they like.
Either way, you can use the code I wrote below to close the toolbar on the
preview window, but if users don't know to click the X in the upper right
corner of the preview or click the door to close the preview without
printing and click the printer icon and then click your Yes to print again
after closing the preview then it sounds like a training session might be
recommended. Either way, I vote no prompts to print after closing a preview
window. Rather, put the print, print dialog, preview question first or on
the toolbar or allow them to click File, Preview or File, Print.
Mike
"TonySper" <
tsperduti@nospambellsouth.net>wrote in message
Quote
Mike,
I hear what you are saying. I did give them the option of print or preview
but some users still clicked the print icon on the preview and printed the
report anyway. You are correct to give them the option first but I wanted
to inhibit the user from printing when they just request the preview.
Thanks for the idea.
Tony
"MikeA" <appell@appellsoftware.com>wrote in message
news:BEEIi.18376$re2.2683@trnddc02...
>Okay - I just ran a test and you can remove the report toolbar
>programmatically but again, I don't recommend it and I think it's much
>better to offer them the choice as per my previous reply. But, if a
>person really wants to do it - here's how: Throw a timer on your form
>and in the timer event ever second or so have this routine execute:
>
>* set the interval on the timer to a second or 250 milliseconds or so
>right before the Report Preview command
>
>* Run the Report .....Preview command
>
>* Test for the printer toolbar
>if wexist("print preview")
>* Release the toolbar
>release window "print preview"
>* Stop checking with the timer now that we have closed the toolbar
>this.interval = 0
>endif
>
>Then you would need to create a common method or subroutine that you send
>all your report commands to so that you don't have reproduce the code for
>all the report commands. I recommend a common routine anyways but I
>still would not recommend removing the toolbar. I subclassed my form and
>created a simple method where I pass my report commands to.
>
>Mike
>
>
>
>"MikeA" <appell@appellsoftware.com>wrote in message
>news:DrEIi.18374$re2.16850@trnddc02...
>>Wouldn't it be better to offer the option(s) BEFORE showing the preview?
>>Most windows apps allow you to click either File, Print Preview or File,
>>Print. If I'm a user and I just want to print something, why bother me
>>with a preview window everytime that I'm just going to close anyways
>>only to have more clicks afterwards to get my printout? In addition, I
>>allow users to Right click on the printer icon on the toolbar in my app
>>and then a menu is displayed to Preview, Print, Print Dialog. Saves
>>several steps this way. This eliminates your problem, improves your user
>>interface and creates less clicks for your users to get what they want.
>>Also, they should always have the option to Cancel at the printer
>>dialog.
>>
>>Mike
>>
>>
>>
>>"TonySper" <tsperduti@nospambellsouth.net>wrote in message
>>news:ObdPYs8%23HHA.4752@TK2MSFTNGP04.phx.gbl...
>>>When you send a report for preview is there a way of eliminating the
>>>command box that appears in the upper left corner that allows the
>>>closing or printing of the report?? The reason is that I first let the
>>>user preview the report and then after they close the preview I bring
>>>up a message box that asks if they want to print the report. It appears
>>>that some users print the report to close it and then print the report
>>>again. Some user get confused easy.
>>>Thanks for any suggestions.
>>>TonySper
>>>
>>>
>>
>>
>
>
-