Saving Worksheets

D

D.Parker

I am trying to save a "worksheet" from the active workbook_A into a new
workbook_B, but I am wanting the user to input a filename to give workbook_B.
I'm assuming I have to create a UserForm to grab the input name from the
user.

Worksheets("from workbook_A").Select
Worksheets("LogHistory").SaveAs = "c:\temp\<filename from UserForm>"

No success. Can anyone prescribe a remedy that is simple? Thank you.

D. Parker
 
D

D.Parker

I am using the GetSaveAsFilename procedure as you suggested and from another
response from the user, but when I go to my folder there is no saved file.
Also, I am only interested in saving the worksheet to a new workbook with the
intention that no VBA programming code will exist in the save file.

This is what I have thus far:

Dim SaveName As Variant
Dim fFilter As String
Dim NewName As Variant

NewName = "P2 LogHistory Shift"
fFilter = "Excel Files (*.xls), *.xls"
SaveName = Application.GetSaveAsFilename _
(NewName, fileFilter:=fFilter)

Any adjustments to save a specific worksheet to a new workbook with no VBA
code saved is appreciated?
 

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

Top