View Single Post
  #3   Report Post  
DM HD
 
Posts: n/a
Default

Thanks for the reply on this.

From what i can see this might work. However I do not see how it will add
the names or information in to the cells. I might not be reading it right.

But this is what I am trying to do.

I have one worksheet with the information.

A:1 down to 313 has last names B has first names C has Client number and E
has date.

The Tempale document has the following that has to be duplicated. Will need
to have the above info placed in to.

Cells d,e,f,g,h,i,j,kl, row 4 are mearged to be one cell to have Last name
Cells o,p,q,r,s,t,u,v row 4 are for First name
cells z,aa,ab,ac row 4 are for Middle
Cells d,e,f,g,h,i,j,kl, row 8
And Client number am,an,ao,ap,aq row 2

I was told that here might be a limit how many worksheets that can be in a
document. Is it only up to 256? If so we ware willing to 2 documents.



"Dave Peterson" wrote:

If you have those names/numbers in a range of cells (like A1:A250 of a worksheet
named List), you could run a macro.

This may give you an idea:

Option Explicit
Sub testme01()

Dim TemplateWks As Worksheet
Dim ListWks As Worksheet
Dim ListRng As Range
Dim myCell As Range

Set TemplateWks = Worksheets("Template")
Set ListWks = Worksheets("list")

With ListWks
Set ListRng = .Range("a1", .Cells(.Rows.Count, "A").End(xlUp))
End With

For Each myCell In ListRng.Cells
TemplateWks.Copy after:=Worksheets(Worksheets.Count)
On Error Resume Next
ActiveSheet.Name = myCell.Value
If Err.Number < 0 Then
MsgBox "Please fix: " & ActiveSheet.Name
Err.Clear
End If
On Error GoTo 0
Next myCell
End Sub

If you're new to macros, you may want to read David McRitchie's intro at:
http://www.mvps.org/dmcritchie/excel/getstarted.htm

DM HD wrote:

I have an issue at the office where a co-worker is asking how to copy a
template excel worksheet 250 times to a workbook, but have first, last name
and file number filled in on each copy.

So have have 250 name's each having a file number. Each tab or sheet will
have a name and a file number.


--

Dave Peterson