URGENT! Linking cells to file name save as

  • Thread starter Thread starter sowetoddid
  • Start date Start date
S

sowetoddid

I have a file that will be updated and saved every month. Each month,
cell A1 is updated with a new month and A2 with a new year.

How can I make it so that...

When I chose File > Save As, the month and year automatically appear in
the save as field.


Please respond quickly. I have short notice.


Thanks!!!
 
Is this impossible??

Maybe you're pressing it just a little bit to hard. One idea (not
tested):

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)
Dim fileSaveName
fileSaveName =
Application.GetSaveAsFilename(InitialFileName:="Test.xls")
If fileSaveName <> False Then
MsgBox "Save as " & fileSaveName
End If
Cancel = True
End Sub

Replace the InitialFilename with a reference to your cell. e.g.
fileSaveName =
Application.GetSaveAsFilename(InitialFileName:=Range("A1").Value &
".xls")

just an idea, will also be triggered then just saving the file. As I
said just an idea to play with
Frank
 
Back
Top