Saving file with date variable

  • Thread starter Thread starter Steel Monkey
  • Start date Start date
S

Steel Monkey

Hi All

Hopefully just a quick question :

I am trying to save a file as a .csv. See below code:

Code:
--------------------
fileSaveName = Application.GetSaveAsFilename("C:\Documents and Settings\My Documents\Testing\excel\" & empinput, fileFilter:="CSV Files (*.csv), *.csv")
--------------------


empinput is a variable which works fine, at the end of the filename
though i need the current month inserted in mm format

i.e. 22208 'if empinput = 222
can anyone help me with this ??

Thanks in advance!!
 
Problem solved. In case any one is wondering here i got the current
month as something i could use.


Code:
--------------------
Dim mystr
mystr = Format(Date, "mm")
--------------------


then just used this:

Code:
 

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

Similar Threads


Back
Top