Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro to copy
I have a sheet that comrpise TWO blocks of data
Block A goes from A1 to g20 displays chores that HAVE been done Block B goes from A100 to G130 displays chores that HAVE TO BE DONE Once a chore is done I want to select that line in block B and have a macro copy that line to the bottom of block A above I would appreciate any help you can give me thanks |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Macro to copy
You could add a button from the Forms toolbar (or use a shortcut key or even
Alt-F8) to run a macro that copies the cell with the activecell on it: Option Explicit Sub testme() Dim NextRow As Long With ActiveSheet 'after the end of the first group, but before the start 'of the second. I used row 88. NextRow = .Cells(88, "A").End(xlUp).Row + 1 'some minor checks If ActiveCell.Row < 100 Then Beep 'or give a message MsgBox "Move to the second group!" Else ActiveCell.EntireRow.Copy _ Destination:=.Cells(NextRow, "A") End If End With End Sub If you're new to macros: Debra Dalgleish has some notes how to implement macros he http://www.contextures.com/xlvba01.html David McRitchie has an intro to macros: http://www.mvps.org/dmcritchie/excel/getstarted.htm Ron de Bruin's intro to macros: http://www.rondebruin.nl/code.htm (General, Regular and Standard modules all describe the same thing.) On 07/23/2010 09:26, wrote: I have a sheet that comrpise TWO blocks of data Block A goes from A1 to g20 displays chores that HAVE been done Block B goes from A100 to G130 displays chores that HAVE TO BE DONE Once a chore is done I want to select that line in block B and have a macro copy that line to the bottom of block A above I would appreciate any help you can give me thanks -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Change a Macro - Copy in Columns instead of copy in Rows | Excel Programming | |||
Copy workbook, don't copy macro | Excel Discussion (Misc queries) | |||
Macro to copy and paste values (columns)I have a macro file built | Excel Programming | |||
how to count/sum by function/macro to get the number of record to do copy/paste in macro | Excel Programming |