Hi

Try :

Sub Mtest()
Dim ws2 As Worksheet
    Dim c As Range
    For Each c In Range("A1:A" & Cells(Rows.Count, 1).End(xlUp).Row)
      If c.MergeCells Then
      c.CurrentRegion.Copy
      Set ws2 = Worksheets.Add(After:=Sheets(Sheets.Count))
      With ws2
      .Name = c.Value
      .Range("A1").PasteSpecial Paste:=xlPasteValues
       Application.CutCopyMode = False
      .ListObjects.Add(xlSrcRange,
.UsedRange.Offset(1).Resize(ActiveSheet.UsedRange.Rows.Count - 1), ,
xlYes).Name = " "
      .Range("D2:F" & Cells(Rows.Count, 6).End(xlUp).Row).NumberFormat =
"0.00%"
      .Range("A2").Resize(3).EntireRow.Insert shift:=xlDown
      .Range("A3").Formula = "=""Number of School in Table :
""&COUNTA(C[1])-1"
      End With
      End If
      Next
End Sub

HTH
Mahesh

On Thu, Dec 22, 2011 at 8:02 AM, 0 1 <hhholme...@gmail.com> wrote:

> (Second attempt to attach file. ... )
>
> Attached is a file with some sample tables. The README worksheet includes
> some notes and the tasks I'm trying to automate (the main one is moving the
> tables to separate worksheets, but I'd of course welcome suggestions for
> any of the others).
>
> Thanks for any guidance.
>
> --
> FORUM RULES (934+ members already BANNED for violation)
>
> 1) Use concise, accurate thread titles. Poor thread titles, like Please
> Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice
> will not get quick attention or may not be answered.
>
> 2) Don't post a question in the thread of another member.
>
> 3) Don't post questions regarding breaking or bypassing any security
> measure.
>
> 4) Acknowledge the responses you receive, good or bad.
>
> 5) Cross-promotion of, or links to, forums competitive to this forum in
> signatures are prohibited.
>
> NOTE : Don't ever post personal or confidential data in a workbook. Forum
> owners and members are not responsible for any loss.
>
>
> ------------------------------------------------------------------------------------------------------
> To post to this group, send email to excel-macros@googlegroups.com
>

-- 
FORUM RULES (934+ members already BANNED for violation)

1) Use concise, accurate thread titles. Poor thread titles, like Please Help, 
Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get 
quick attention or may not be answered.

2) Don't post a question in the thread of another member.

3) Don't post questions regarding breaking or bypassing any security measure.

4) Acknowledge the responses you receive, good or bad.

5)  Cross-promotion of, or links to, forums competitive to this forum in 
signatures are prohibited. 

NOTE  : Don't ever post personal or confidential data in a workbook. Forum 
owners and members are not responsible for any loss.

------------------------------------------------------------------------------------------------------
To post to this group, send email to excel-macros@googlegroups.com

Reply via email to