Hi,
I have a spreadsheet for filling student mark details.
And I am using the below code to create the workbooks that I got at here.
'Sub Michael_Create_workbooks()
Dim NoOfFiles As Long, source As Worksheet
Set source = ThisWorkbook.Sheets(1)
For i = 2 To [A65536].End(xlUp).Row
Workbooks.Add (1)
ActiveSheet.[C5] = source.Range("C" & i)
ActiveSheet.[C6] = source.Range("B" & i)
ActiveWorkbook.SaveAs ThisWorkbook.Path & "" & source.Range("A" & i) & ".xls", xlWorkbookNormal
ActiveWorkbook.Close True
Next i
MsgBox "All Files has been created in the same folder"
End Sub'
With this code I wish to copy the current worksheet format and create workbooks like this workbook.
Please find the sample workbook at here:
https://www.dropbox.com/s/q0c6w3nynub732k/Arun.xls
Kindly advise me.
Regards,
Michael
I have a spreadsheet for filling student mark details.
And I am using the below code to create the workbooks that I got at here.
'Sub Michael_Create_workbooks()
Dim NoOfFiles As Long, source As Worksheet
Set source = ThisWorkbook.Sheets(1)
For i = 2 To [A65536].End(xlUp).Row
Workbooks.Add (1)
ActiveSheet.[C5] = source.Range("C" & i)
ActiveSheet.[C6] = source.Range("B" & i)
ActiveWorkbook.SaveAs ThisWorkbook.Path & "" & source.Range("A" & i) & ".xls", xlWorkbookNormal
ActiveWorkbook.Close True
Next i
MsgBox "All Files has been created in the same folder"
End Sub'
With this code I wish to copy the current worksheet format and create workbooks like this workbook.
Please find the sample workbook at here:
https://www.dropbox.com/s/q0c6w3nynub732k/Arun.xls
Kindly advise me.
Regards,
Michael