Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create New Wk
Hi folks: I have an Excel file with a list of 150 names or more, one name per cell in column A. This list changes weekly. I need to create a workbook with using those names one name per worksheet, meaning each tab name in the new workbook would be the list. Any thoughts? thanks in advance :) -- halem2 ------------------------------------------------------------------------ halem2's Profile: http://www.excelforum.com/member.php...fo&userid=9930 View this thread: http://www.excelforum.com/showthread...hreadid=556892 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create New Wk
On Thu, 29 Jun 2006 08:38:36 -0500, halem2 wrote:
Hi folks: I have an Excel file with a list of 150 names or more, one name per cell in column A. This list changes weekly. I need to create a workbook with using those names one name per worksheet, meaning each tab name in the new workbook would be the list. Any thoughts? thanks in advance :) Sub GenerateWB() Dim rng As Excel.Range Dim wkb As Excel.Workbook Workbooks.Add Set wkb = ActiveWorkbook Set rng = Me.Range("A1") Do While rng.Value < "" wkb.Sheets.Add wkb.ActiveSheet.Name = rng.Value Set rng = rng.Offset(1, 0) Loop End Sub -- PL |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create New Wk
thanks. I'm getting en error pointing to invalid use of ME. -- halem2 ------------------------------------------------------------------------ halem2's Profile: http://www.excelforum.com/member.php...fo&userid=9930 View this thread: http://www.excelforum.com/showthread...hreadid=556892 |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create New Wk
On Thu, 29 Jun 2006 09:18:15 -0500, halem2 wrote:
thanks. I'm getting en error pointing to invalid use of ME. This code works fine if you put in into a worksheet module. If you want to use it as a separate module, use ThisWorkbook.Sheets("sheetname") instead of Me -- PL |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create New Wk
thanks a lot. I was able to ncorporate your code into my project. Thanks again. -- halem2 ------------------------------------------------------------------------ halem2's Profile: http://www.excelforum.com/member.php...fo&userid=9930 View this thread: http://www.excelforum.com/showthread...hreadid=556892 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Create a macro to create excel line graph with coloured pointers anddata lables | Charts and Charting in Excel | |||
How to create adress list so can mail merge and create labels? | Excel Discussion (Misc queries) | |||
How to create a form to insert a hyerlink.VBA code to create a for | Excel Discussion (Misc queries) | |||
Create dictionary of terms, create first time user site | New Users to Excel | |||
need to create a formula to create a timesheet but haven't a clue | Excel Discussion (Misc queries) |