Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Writing a macro


I have one excel sheet which is exported from some other programme.
There are several blocks in it. Each block is seperated by one or two
blank rows. I want to seperate these blocks in different excel tabs.
How can I do that? Can anyone helpme for this?


--
Sylvia
------------------------------------------------------------------------
Sylvia's Profile: http://www.excelforum.com/member.php...o&userid=30300
View this thread: http://www.excelforum.com/showthread...hreadid=499679

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,441
Default Writing a macro

Sylvia,

Select your sheet, and run the macro below.

HTH,
Bernie
MS Excel MVP


Sub Macro1()
Dim myArea As Range
Dim Counter As Integer

Counter = 0

For Each myArea In Cells.SpecialCells(xlCellTypeConstants, 23).Areas
Counter = Counter + 1
Worksheets.Add.Name = "Area " & Counter
myArea.Copy Range("A1")
Next myArea

End Sub


"Sylvia" wrote in message
...

I have one excel sheet which is exported from some other programme.
There are several blocks in it. Each block is seperated by one or two
blank rows. I want to seperate these blocks in different excel tabs.
How can I do that? Can anyone helpme for this?


--
Sylvia
------------------------------------------------------------------------
Sylvia's Profile: http://www.excelforum.com/member.php...o&userid=30300
View this thread: http://www.excelforum.com/showthread...hreadid=499679



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
Help writing a macro IcarusFB Excel Programming 8 December 31st 05 11:44 PM
help writing macro Alison Excel Programming 1 September 23rd 04 10:47 PM
VBA-writing a macro Don Guillett[_4_] Excel Programming 1 August 31st 04 01:49 PM
Macro Writing Help? Richard[_22_] Excel Programming 2 December 31st 03 07:39 PM
Writing Macro Tammy Klein Excel Programming 1 October 3rd 03 09:13 PM


All times are GMT +1. The time now is 08:59 PM.

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"