Deleting Cell entries then save and overwrite template

  • Thread starter Thread starter RPIJG
  • Start date Start date
R

RPIJG

I'd like to be able to delete the entries in certain cells, then sav
the file as a template (overwriting an existing template), that wa
some information I have entered will be saved in the template whil
other information is removed. How would I go about doing this
 
Open the workbook you want to use, make the changes, do File => Save As,
specify the name of the old template and specify file type in the dropdown
as .xlt.
 
ok, that answers my question but I didn't qualify my question wel
enough, I'd like to do this programmatically, sorry
 
sPath = "C:\Myfiles\"
ActiveWorkbook.Saveas Filename:=sPath & _
"MyOldTemplate.xlt", FileFormat:=xltemplate
 
for your existing code, Selection is misspelled

you could just do

Range("D13:H13").Clearcontents
 

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