![]() |
Formatting macro runs real slow due to network printer - best workaround?
Hi All
I have a macro that formats raw data to make it look like an old legacy report for some people who refuse to move with the times! :) This results in adding extra blank rows in the data. When my default printer is set to my network printer the macro runs very slow. When I change the default printer to the image writer the code runs quicker: Application.ActivePrinter = "Microsoft Office Document Image Writer on Ne00:" I am not really happy with this solution though as I sure this fix wont work on someones machine somewhere. It seems like a hack rather than a neat solution. Additionaly to set back to the network printer takes 12 seconds! Is there a better solution where I dont mess with the users default printer? I have tried clearing the print area before the macro runs and also setting the print area to a single cell. No luck. Cheers for any thoughts Chrisso |
Formatting macro runs real slow due to network printer - best workaround?
On 25 Aug, 15:15, Chrisso wrote:
Hi All I have a macro that formats raw data to make it look like an old legacy report for some people who refuse to move with the times! :) This results in adding extra blank rows in the data. When my default printer is set to my network printer the macro runs very slow. When I change the default printer to the image writer the code runs quicker: Application.ActivePrinter = "Microsoft Office Document Image Writer on Ne00:" I am not really happy with this solution though as I sure this fix wont work on someones machine somewhere. It seems like a hack rather than a neat solution. Additionaly to set back to the network printer takes 12 seconds! Is there a better solution where I dont mess with the users default printer? I have tried clearing the print area before the macro runs and also setting the print area to a single cell. No luck. Cheers for any thoughts Chrisso Hmmm - I have already found that there are at least two variants for the Microsoft Office Document Image Writer "port" or whatever "Ne00" means. Application.ActivePrinter = "Microsoft Office Document Image Writer on Ne00:" Application.ActivePrinter = "Microsoft Office Document Image Writer on Ne01:" If this is the best workaround does anyone know how I can lookup which "port" to append to the end of the image writer text? Cheers Chrisso |
Formatting macro runs real slow due to network printer - best workaround?
Suggestions/comments...
When adding rows, you should be running the loop from the bottom up. Screenupdating should be turned off. Minimize calls to PageSetup - only change/set those items absolutely necessary. *Turn off the display of Page breaks - and do it again after every call to PageSetup.* Out of date printer drivers can cause a lot of printing problems. Are yours current? The users? -- Jim Cone Portland, Oregon USA http://www.mediafire.com/PrimitiveSoftware .. .. .. "Chrisso" wrote in message ... On 25 Aug, 15:15, Chrisso wrote: Hi All I have a macro that formats raw data to make it look like an old legacy report for some people who refuse to move with the times! :) This results in adding extra blank rows in the data. When my default printer is set to my network printer the macro runs very slow. When I change the default printer to the image writer the code runs quicker: Application.ActivePrinter = "Microsoft Office Document Image Writer on Ne00:" I am not really happy with this solution though as I sure this fix wont work on someones machine somewhere. It seems like a hack rather than a neat solution. Additionaly to set back to the network printer takes 12 seconds! Is there a better solution where I dont mess with the users default printer? I have tried clearing the print area before the macro runs and also setting the print area to a single cell. No luck. Cheers for any thoughts Chrisso Hmmm - I have already found that there are at least two variants for the Microsoft Office Document Image Writer "port" or whatever "Ne00" means. Application.ActivePrinter = "Microsoft Office Document Image Writer on Ne00:" Application.ActivePrinter = "Microsoft Office Document Image Writer on Ne01:" If this is the best workaround does anyone know how I can lookup which "port" to append to the end of the image writer text? Cheers Chrisso |
All times are GMT +1. The time now is 09:23 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com