Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Need to copy rows in Sheet1 to different worksheets
I tried it and get the following error: Run-time error '9' : Subscript out of range Please help (sorry about this, but as I said, I am completely new t this). Thank -- minx200 ----------------------------------------------------------------------- minx2001's Profile: http://www.excelforum.com/member.php...fo&userid=1516 View this thread: http://www.excelforum.com/showthread.php?threadid=27176 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Need to copy rows in Sheet1 to different worksheets
Hi
Set ws1 = Sheets("Sheet1") Sheets("Sheet1") is the sheet with the data If the sheet with the data not exist you get a error 9 Use a range like this Set rng = ws1.Range("A1:G100") The names in the is example must be in column A If not change this line rng.Columns(1).AdvancedFilter _ To rng.Columns(3).AdvancedFilter _ If the names are in column C -- Regards Ron de Bruin http://www.rondebruin.nl "minx2001" wrote in message ... I tried it and get the following error: Run-time error '9' : Subscript out of range Please help (sorry about this, but as I said, I am completely new to this). Thanks -- minx2001 ------------------------------------------------------------------------ minx2001's Profile: http://www.excelforum.com/member.php...o&userid=15168 View this thread: http://www.excelforum.com/showthread...hreadid=271761 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
copy data from sheet2 to sheet1 when sheet2 has variable # of rows | Excel Discussion (Misc queries) | |||
Copy Rows with a cell value 0 from several worksheets to a new sh | Excel Worksheet Functions | |||
Copy rows with a cell value 0 from several worksheets to a new sh | Excel Worksheet Functions | |||
Need to copy rows in Sheet1 to different worksheets | Excel Programming | |||
Sheet1 object not Worksheets("Sheet1") | Excel Programming |