#1   Report Post  
Posted to microsoft.public.excel.misc
HELP
 
Posts: n/a
Default MACRO QUESTION

I have a situation in which a file is sent with many tabs. Every tab has the
same information just different part numbers ex. So I would like to create a
macro that would enable me to extract the data from each tab and input into a
summary tab which the Macro would include. But if I record a macro the tab
names and the number of tabs change with each file. Any suggestions?
  #2   Report Post  
Posted to microsoft.public.excel.misc
Bob Phillips
 
Posts: n/a
Default MACRO QUESTION

On Error Resume Next
Set sh = Worksheets("Summary")
On Error Goto 0
If sh Is N othing Then
Worksheets.Add.Name = "Summary
End If
Worksheets("Summary").Cells.ClearContents

For Each sh In ActiveWorkbook.Worksheets
If sh.Name < "Summary" Then
i=i+1
Worksheets("Summary").Cells(i,"A").Value = sh.Name
End If
Next sh

--
HTH

Bob Phillips

(replace somewhere in email address with googlemail if mailing direct)

"HELP" wrote in message
...
I have a situation in which a file is sent with many tabs. Every tab has

the
same information just different part numbers ex. So I would like to create

a
macro that would enable me to extract the data from each tab and input

into a
summary tab which the Macro would include. But if I record a macro the tab
names and the number of tabs change with each file. Any suggestions?



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
Quick Macro question - How to delete two rows then skip one - and repeat David Smithz Excel Discussion (Misc queries) 3 March 3rd 06 02:58 PM
Excel Macro Question billrl34 Excel Worksheet Functions 1 December 19th 05 10:38 PM
using a macro question revisited Adam Kroger Excel Discussion (Misc queries) 4 December 16th 05 03:37 PM
Excel Macro Question about Conditional Formatting David Britton via OfficeKB.com New Users to Excel 3 February 10th 05 02:23 PM
Attn: Dave P. Question re Pix Calls via Macro DocuMike Excel Discussion (Misc queries) 1 January 10th 05 01:38 AM


All times are GMT +1. The time now is 03:50 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"