Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

disabling printer button in print preview toolbar 1

Status
Not open for further replies.

vdeveloper

Programmer
Aug 5, 2000
42
IN
Hi all

When I issue the "report form xxx preview" command, the results are shown in preview mode with a toolbar for navigation printing etc. How can I disable the print button in this toolbar? I need to either disable or make the button invisible based on certain conditions.

Thanks in advance

Vdevelop
 
V. Develop-

Ditto here. I've failed in my quest, hope someone can answer
this.

Jack
 
Yup, it's doable!
The following is from a reply to an identical question on the neswgroups:
"You CAN remove the print button from the preview toolbar.
Roughly:
1. make a backup of your foxuser files
2. from vfp modify the print preview tool bar to remove the print button.
Results are stored in the foxuser (resource) dbf
3. save the foxuser dbf as some other name.
4. compile the resource dbf into your exe. (this is optional)
5. In your print preview commands (I use a function to do this) SET RESOURCE TO your resource dbf from step 3.
6. Do your PRINT PREVIEW
7. ReSET RESOURCE TO your usual resource file.

This works really well.

Nancy Folsom"
----
Note: This is a little more detail for step #2 above:
At the VFP Menu, choose View, ToolBars..., Check Print Preview, click on Customize, then select Print Preview. Now click on the Print button on the toolbar, and drag-and-drop it onto the "Customize Toolbar" window. It should now be gone from the toolbar.

Rick
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top