Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8
Default prob. running macro from diff. sheet

I have this line in my macro:

Worksheets("ABC").Columns("A:A").Select

If I run this macro when I am in a different sheet, it gives the run-time
error 1004. How can I avoid this? What is the reason?

Thx in advance.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8
Default prob. running macro from diff. sheet

sorry, the answer is activating the sheet before that line:

Sheets("ABC").Activate

i did the search but with "sheeeet" in the search-box, sorry :)

"darxoul" wrote:

I have this line in my macro:

Worksheets("ABC").Columns("A:A").Select

If I run this macro when I am in a different sheet, it gives the run-time
error 1004. How can I avoid this? What is the reason?

Thx in advance.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Clearing Check Boxes & Running a diff Macro when unchecking the ch Vick Excel Discussion (Misc queries) 6 May 30th 07 08:44 PM
Find based on cond. 4matting? Replace as ALT-Enter? (2 diff prob HopefulTraveller Excel Discussion (Misc queries) 7 May 18th 07 05:54 PM
Don't show sheet switches when running macro Ben Excel Programming 4 May 25th 05 02:10 PM
Running Macro on every sheet in Workbook !!! Jako[_65_] Excel Programming 14 August 9th 04 01:06 AM
excel simple prob w/running subtotals diesel cdg Excel Programming 1 April 1st 04 09:51 PM


All times are GMT +1. The time now is 05:19 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"