Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello All,
I created what I thought was a really simple workbook, but have run across a macro error that I can't seem to solve. Probably really simple for some, but has stumped me on working any further on the workbook: I recorded a macro to hide a column on a specific worksheet (code below): Sheets("Sheet1").Select Columns("H:H").Select Selection.EntireColumn.Hidden = True However, when I copied the code to a command button on another worksheet I get: "Run-time error '1004': Select method of Range class failed" The macro works fine when I run it through the menu, however it will not work with the command button. When I click on the Debug, it highlights the "Columns("H:H").Select" Any insight will be appreciated... |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Command Button to show/hide a different worksheet | Excel Discussion (Misc queries) | |||
Hide command button | Excel Programming | |||
Command Button to Hide/Unhide Rows | Excel Discussion (Misc queries) | |||
how do you hide a forms command button | Excel Programming | |||
Hide command button on worksheet | Excel Programming |