For now I'm trying to just work out how user input works, but my goal is to have a macro which will pause and ask the user to select the cells to paste into and then paste the relevant data where the user has selected.
In a possibly clearer form:
- macro copies data
- macro asks for user to select cell
- macro pastes data into user selected cell
I have this (not working) code so far:
Any tips on how I could make this work would be great - could be a basic error as it's been a while since I played with VBA so I'm a little rusty, but I have briefly tried before without much luck!
In a possibly clearer form:
- macro copies data
- macro asks for user to select cell
- macro pastes data into user selected cell
I have this (not working) code so far:
Code:
Sub User_Input() ' ' User Input Macro ' Takes input from user to select a cell and paste contents from A1 ' Dim rng As Range Set rng = Application.InputBox(prompt:="Select a cell", Type:=8) Cells(1, 1).Copy Cells(rng).Paste End Sub
Comment