![]() |
Help with a Clear Form Macro
Hey guys im having trouble figuring out how to make a clear form butto
in Macros for my excel spread sheet. It alread contained one the worke fine until i had to move the from around a bit. The macro looked like this originally: Sub clear123() ' ' clear123 Macro ' Macro recorded 12/31/02 by ' ' Range("D15:E19,G15:G19,G4:J4,G5:J5,G6:J6,G8:J8,G9: J9,K14:N20,R15:U28,K24:N28,D24:G28 _ ).Select Range("D24").Activate ActiveWindow.LargeScroll ToRight:=2 ActiveWindow.SmallScroll ToRight:=1 Range( _ "D15:E19,G15:G19,G4:J4,G5:J5,G6:J6,G8:J8,G9:J9,K14 :N20,R15:U28,K24:N28,D24:G28,AM8:AM12,AP8:AP12,AN2 4:BA24,AN26:BA26 _ ).Select Range("AN26").Activate Selection.ClearContents ActiveWindow.ScrollColumn = 1 Application.Run "SellingcoveragesheetA.xls!sfcsfitscreen" End Sub the problem is when i try to adjust ranges like D15:E19 to somethin less or more the macro dosent work at all. Im not sure how to save th changes i make or anyting that can help me at this point. Any advice would be appreciated. Eri -- Message posted from http://www.ExcelForum.com |
Help with a Clear Form Macro
What does your changed code look like, and what error do you get?
-- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "DangerMouse114 " wrote in message ... Hey guys im having trouble figuring out how to make a clear form button in Macros for my excel spread sheet. It alread contained one the worked fine until i had to move the from around a bit. The macro looked like this originally: Sub clear123() ' ' clear123 Macro ' Macro recorded 12/31/02 by ' ' Range("D15:E19,G15:G19,G4:J4,G5:J5,G6:J6,G8:J8,G9: J9,K14:N20,R15:U28,K24:N28 ,D24:G28" _ ).Select Range("D24").Activate ActiveWindow.LargeScroll ToRight:=2 ActiveWindow.SmallScroll ToRight:=1 Range( _ "D15:E19,G15:G19,G4:J4,G5:J5,G6:J6,G8:J8,G9:J9,K14 :N20,R15:U28,K24:N28,D24:G 28,AM8:AM12,AP8:AP12,AN24:BA24,AN26:BA26" _ ).Select Range("AN26").Activate Selection.ClearContents ActiveWindow.ScrollColumn = 1 Application.Run "SellingcoveragesheetA.xls!sfcsfitscreen" End Sub the problem is when i try to adjust ranges like D15:E19 to something less or more the macro dosent work at all. Im not sure how to save the changes i make or anyting that can help me at this point. Any advice would be appreciated. Eric --- Message posted from http://www.ExcelForum.com/ |
Help with a Clear Form Macro
Never mind. I figured it all out. LOL... just took me sometime. I have
a new question though that I am going to post under a new subject -- Message posted from http://www.ExcelForum.com |
All times are GMT +1. The time now is 09:40 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com