![]() |
Print macros don't work on all printers
I use macros to print some portions of my worksheets. Included in the macro
is print setup commands. When I try to print on some different printes, the macro doesn't work. It seems to have something in the setup being different on other printers. How can I change macro to work on all printers? |
Print macros don't work on all printers
Try keeping only the code that you need in your macro.
If you're not changing a setting, then don't include it in your code. If you used the macro recorder to generate your code, you may have lots of extra lines in that procedure. dford wrote: I use macros to print some portions of my worksheets. Included in the macro is print setup commands. When I try to print on some different printes, the macro doesn't work. It seems to have something in the setup being different on other printers. How can I change macro to work on all printers? -- Dave Peterson |
Print macros don't work on all printers
I am using the macro recorder. Is there a way to tell which code I don't need?
"Dave Peterson" wrote: Try keeping only the code that you need in your macro. If you're not changing a setting, then don't include it in your code. If you used the macro recorder to generate your code, you may have lots of extra lines in that procedure. dford wrote: I use macros to print some portions of my worksheets. Included in the macro is print setup commands. When I try to print on some different printes, the macro doesn't work. It seems to have something in the setup being different on other printers. How can I change macro to work on all printers? -- Dave Peterson |
Print macros don't work on all printers
Two ways -
Visually examine the macro recorded and just delete entries that are obviously not things you were planning on setting up anyhow. The second way is to run the macro and when it errors out, click the [Debug] button offered. The offending feature will be highlighted in the code. Delete that line of the code, press [F5] to continue running the code. Repeat until code works for you. "dford" wrote: I am using the macro recorder. Is there a way to tell which code I don't need? "Dave Peterson" wrote: Try keeping only the code that you need in your macro. If you're not changing a setting, then don't include it in your code. If you used the macro recorder to generate your code, you may have lots of extra lines in that procedure. dford wrote: I use macros to print some portions of my worksheets. Included in the macro is print setup commands. When I try to print on some different printes, the macro doesn't work. It seems to have something in the setup being different on other printers. How can I change macro to work on all printers? -- Dave Peterson |
Print macros don't work on all printers
That should work for me. Thanks for the help.
"JLatham" wrote: Two ways - Visually examine the macro recorded and just delete entries that are obviously not things you were planning on setting up anyhow. The second way is to run the macro and when it errors out, click the [Debug] button offered. The offending feature will be highlighted in the code. Delete that line of the code, press [F5] to continue running the code. Repeat until code works for you. "dford" wrote: I am using the macro recorder. Is there a way to tell which code I don't need? "Dave Peterson" wrote: Try keeping only the code that you need in your macro. If you're not changing a setting, then don't include it in your code. If you used the macro recorder to generate your code, you may have lots of extra lines in that procedure. dford wrote: I use macros to print some portions of my worksheets. Included in the macro is print setup commands. When I try to print on some different printes, the macro doesn't work. It seems to have something in the setup being different on other printers. How can I change macro to work on all printers? -- Dave Peterson |
All times are GMT +1. The time now is 04:30 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com