Replace cell values with Macro

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a Macro that clears a form, and I want it to replace the cleared cells
with original information.
Here is a brief example of my code:

Range("P3,P4" _ ).Select
Selection.ClearContents

I want range P3, P4 to say "N/A" after it is cleared. Or better yet to just
replace the contents of P3,P4 with "N/A".

Thanks
 
This will replace the cell contents, on Sheet1, with "N/A"

Worksheets("Sheet1").Range("P3:P4").Value = "N/A"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top