View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.newusers
Gary''s Student
 
Posts: n/a
Default Excell Macro Help Please

Let's say that A1 thru A3 contain:
C:\sample
1_25_2006
..xls
and in A4 we put the formula
=A1 & A2 & A3
in A4 then we will see:
C:\sample1_25_2006.xls


in this simple example a2 will be updated with new dates

Then enter and run this tiny macro:


Sub Macro1()
Dim s As String
s = Cells(4, 1)
ActiveWorkbook.SaveAs Filename:= _
s, FileFormat:= _
xlNormal, Password:="", WriteResPassword:="",
ReadOnlyRecommended:=False _
, CreateBackup:=False
End Sub

--
Gary's Student


"Bill Kirk" wrote:

Could anyone show me how to create a macro to save a workbook with file name
plus a date taken from a cell in a worksheet. That is "filename"+"date"
(where "filename" is the name of the workbook and "date" has been manually
input to a cell in one of the worksheets).

thanks