Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Split 1 Master Worksheet to Many


Ok I have one main data sheet and I am looking for a macro to split that
sheet into many spreadsheets.

Each set of data is seperated by a blank row. Data sets are variable.

I have attached 2 spreadsheets to show what i start with and what I am
trying to have when the macro runs through its process.

The "My Master Data sheet.xls" Sheet is the sheet i start with and "My
Goal.xls" is what I want the spreadsheet to look like at the end of the
process.


+-------------------------------------------------------------------+
|Filename: Help.zip |
|Download: http://www.excelforum.com/attachment.php?postid=4815 |
+-------------------------------------------------------------------+

--
Vlad999
------------------------------------------------------------------------
Vlad999's Profile: http://www.excelforum.com/member.php...o&userid=33586
View this thread: http://www.excelforum.com/showthread...hreadid=545755

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 718
Default Split 1 Master Worksheet to Many

'---------------------------------------
Sub SplitMaster()
Dim rSrc As Range
Dim wsDest As Worksheet

Set rSrc = Worksheets("Master").Range("A3")
Do While rSrc.Range("A1").Value < ""
Set wsDest = Worksheets.Add(after:=Worksheets(Worksheets.Count) )
wsDest.Name = rSrc.Range("A1").Value
Set rSrc = Range(rSrc.Range("A1"), _
rSrc.Range("A1").End(xlDown) _
.Resize(, 7) _
)
rSrc.Copy Destination:=wsDest.Range("A1")
Set rSrc = rSrc.Offset(rSrc.Rows.Count + 1)
Loop
End Sub

'---------------------------------------

You may comment out the line :
wsDest.Name = rSrc.Range("A1").Value
if you want your sheets named "Sheet2", "Sheet3", ...

HTH
--
AP

"Vlad999" a écrit
dans le message de news:
...

Ok I have one main data sheet and I am looking for a macro to split that
sheet into many spreadsheets.

Each set of data is seperated by a blank row. Data sets are variable.

I have attached 2 spreadsheets to show what i start with and what I am
trying to have when the macro runs through its process.

The "My Master Data sheet.xls" Sheet is the sheet i start with and "My
Goal.xls" is what I want the spreadsheet to look like at the end of the
process.


+-------------------------------------------------------------------+
|Filename: Help.zip |
|Download:
http://www.excelforum.com/attachment.php?postid=4815 |
+-------------------------------------------------------------------+

--
Vlad999
------------------------------------------------------------------------
Vlad999's Profile:
http://www.excelforum.com/member.php...o&userid=33586
View this thread: http://www.excelforum.com/showthread...hreadid=545755



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Split 1 Master Worksheet to Many


Thank you thats perfec

--
Vlad99
-----------------------------------------------------------------------
Vlad999's Profile: http://www.excelforum.com/member.php...fo&userid=3358
View this thread: http://www.excelforum.com/showthread.php?threadid=54575

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
automatically appending newly added data on worksheet to a master list worksheet tabylee via OfficeKB.com Links and Linking in Excel 0 December 17th 09 04:24 PM
link a cell in the 'Master' worksheet list to a 'Detail' worksheet Paul Condron Excel Programming 12 July 16th 06 10:41 PM
Master sheet to split sheets back to another master sheet FurRelKT Excel Programming 0 May 11th 06 09:28 PM
copy range on every worksheet (diff names) to a master worksheet (to be created) Bernie[_2_] Excel Programming 2 September 22nd 04 03:30 PM
copy range on every worksheet (diff names) to a master worksheet (to be created) Bernie[_3_] Excel Programming 0 September 22nd 04 03:26 PM


All times are GMT +1. The time now is 12:02 PM.

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

About Us

"It's about Microsoft Excel"