How to pause a macro

Lino123

New Member
Joined
Feb 20, 2025
Messages
1
Office Version
  1. 2007
Platform
  1. Windows
Is there a syntax in vba (macro) to copy a formula from a certain cell, then pause the macro to alow me to select two or three cells to paste to, then restarts the macro to paste the copied cell to the selected cells.
 
like this ??

VBA Code:
Sub CopyPaste()
On Error Resume Next

Title = "Copy Paste"
 Set Copy = Application.Selection
Set Copy = Application.InputBox("Chooce Cell/Range want to Copy, then click OK:", Title, Copy.Address, Type:=8)
    
 Set Paste = Application.Selection
Set Paste = Application.InputBox("Chooce Cell/Range want to Paste, then click OK:", Title, Paste.Address, Type:=8)
    
    Copy.Copy Paste

End Sub
 
Upvote 0

Forum statistics

Threads
1,226,837
Messages
6,193,253
Members
453,784
Latest member
Chandni

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top