Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create macro to paste rows of text cells to lower end of other row
I have a set of four rows for each day of the week having several fixed text
columns. How do I write a macro to add further weeks to the end of the previous week? |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create macro to paste rows of text cells to lower end of other row
To find the first empty cell in a column you can use (eg)
*************** dim c as range, s as worksheet set s=thisworkbook.sheets("Sheet1") set c = s.cells(s.rows.count,1).end(xlUp).offset(1,0) *************** c would be the first empty cell in column A Tim "RodFerd" wrote in message ... I have a set of four rows for each day of the week having several fixed text columns. How do I write a macro to add further weeks to the end of the previous week? |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create macro to paste rows of text cells to lower end of other
Tim,
Many thanks for the reply. I tried write in your code a macro, but it did not work; the cursor did not move. Here is what I wrote: Sub Addon() ' 'Addon Macro 'Macro recorded 20/01/2006 by Rod ' 'Keyboard Shortcut: Ctrl+t Dim c As Range, s As Worksheet Set s = ThisWorkbook.Sheets("Sheet1") Set c = s.Cells(s.Rows.Count, 1).End(xlUp).Offset(1, 0) End Sub Any suggestions? Cheers, Rod "Tim Williams" wrote: To find the first empty cell in a column you can use (eg) *************** dim c as range, s as worksheet set s=thisworkbook.sheets("Sheet1") set c = s.cells(s.rows.count,1).end(xlUp).offset(1,0) *************** c would be the first empty cell in column A Tim "RodFerd" wrote in message ... I have a set of four rows for each day of the week having several fixed text columns. How do I write a macro to add further weeks to the end of the previous week? |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Create macro to paste rows of text cells to lower end of other
The code I posted was just one part of what you'd need: it's not supposed to
move the cursor. Your problem isn't described in enough detail to provide much more than that. Post more details if you need more help. Tim "RodFerd" wrote in message ... Tim, Many thanks for the reply. I tried write in your code a macro, but it did not work; the cursor did not move. Here is what I wrote: Sub Addon() ' 'Addon Macro 'Macro recorded 20/01/2006 by Rod ' 'Keyboard Shortcut: Ctrl+t Dim c As Range, s As Worksheet Set s = ThisWorkbook.Sheets("Sheet1") Set c = s.Cells(s.Rows.Count, 1).End(xlUp).Offset(1, 0) End Sub Any suggestions? Cheers, Rod "Tim Williams" wrote: To find the first empty cell in a column you can use (eg) *************** dim c as range, s as worksheet set s=thisworkbook.sheets("Sheet1") set c = s.cells(s.rows.count,1).end(xlUp).offset(1,0) *************** c would be the first empty cell in column A Tim "RodFerd" wrote in message ... I have a set of four rows for each day of the week having several fixed text columns. How do I write a macro to add further weeks to the end of the previous week? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
copy multiple worksheets of a workbook, and paste onto a Word document ( either create new doc file or paste onto an existing file.) I need this done by VBA, Excel Macro | Excel Programming | |||
How do I create upper/lower case letters in cells? | Excel Discussion (Misc queries) | |||
Macro cut and paste quits, can't re-create | Excel Programming | |||
Macro to delete rows with text cells | Excel Programming | |||
Macro to Create text file from range of cells? | Excel Programming |