View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
whyloo whyloo is offline
external usenet poster
 
Posts: 1
Default Macro to Cut-And-Paste Text

Hi,

I'm creating a timeline which has special formatting for each new activity.
I want to create a macro that will insert a new activity at the cursor every
time I run it. So far, I have:

Sub Activity()
'
' Activity Macro
' This macro adds a new activity.
'
' Keyboard Shortcut: Ctrl+Shift+A
'
ActiveWindow.SmallScroll Down:=-36
Rows("9:10").Select
Selection.Copy
ActiveWindow.SmallScroll Down:=30
Rows("42:42").Select
ActiveSheet.Paste
Rows("42:42").Select
Application.CutCopyMode = False
End Sub

But, what this does is paste the text from Rows 9 and 10 always into Rows
42. How can I write the macro so it will paste the text into whatever row is
active?

Thanks!