Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() I have a macro that runs an application, and creates new files with the results. I want to have the date (and if possible time) of the run in my file name. But I am not able to do this with the Date function as I guess the results it throws is not in the text format. How can I do this in VB? Right now, to do this, I am typing the date in "" in one of the cellls, but I am sure there would be better ways. Suggestions please. Thanks, Kapil -- kapil.dalal ------------------------------------------------------------------------ kapil.dalal's Profile: http://www.excelforum.com/member.php...o&userid=23853 View this thread: http://www.excelforum.com/showthread...hreadid=375005 |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Use in VBA myVar = Format(Now(), "dd mmm yy") Mangesh -- mangesh_yadav ------------------------------------------------------------------------ mangesh_yadav's Profile: http://www.excelforum.com/member.php...o&userid=10470 View this thread: http://www.excelforum.com/showthread...hreadid=375005 |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() sFilename = "myFile-" & Format(Now,"yyyymmdd hhmmss") & ".xls" -- HTH Bob Phillips "kapil.dalal" wrote in message ... I have a macro that runs an application, and creates new files with the results. I want to have the date (and if possible time) of the run in my file name. But I am not able to do this with the Date function as I guess the results it throws is not in the text format. How can I do this in VB? Right now, to do this, I am typing the date in "" in one of the cellls, but I am sure there would be better ways. Suggestions please. Thanks, Kapil -- kapil.dalal ------------------------------------------------------------------------ kapil.dalal's Profile: http://www.excelforum.com/member.php...o&userid=23853 View this thread: http://www.excelforum.com/showthread...hreadid=375005 |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Thanks a lot. It works. -- kapil.dalal ------------------------------------------------------------------------ kapil.dalal's Profile: http://www.excelforum.com/member.php...o&userid=23853 View this thread: http://www.excelforum.com/showthread...hreadid=375005 |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Thanks for the feedback Manges -- mangesh_yada ----------------------------------------------------------------------- mangesh_yadav's Profile: http://www.excelforum.com/member.php...fo&userid=1047 View this thread: http://www.excelforum.com/showthread.php?threadid=37500 |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
This link might give you some ideas:
http://www.bygsoftware.com/Excel/VBA/saving.htm -- Andy Wiggins FCCA www.BygSoftware.com Excel, Access and VBA Consultancy Home of Excel Save and Backup - "kapil.dalal" wrote in message ... I have a macro that runs an application, and creates new files with the results. I want to have the date (and if possible time) of the run in my file name. But I am not able to do this with the Date function as I guess the results it throws is not in the text format. How can I do this in VB? Right now, to do this, I am typing the date in "" in one of the cellls, but I am sure there would be better ways. Suggestions please. Thanks, Kapil -- kapil.dalal ------------------------------------------------------------------------ kapil.dalal's Profile: http://www.excelforum.com/member.php...o&userid=23853 View this thread: http://www.excelforum.com/showthread...hreadid=375005 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Appending data from one WB to another WB by date: | Setting up and Configuration of Excel | |||
set filename to <filename-date on open | Excel Worksheet Functions | |||
date in filename | Excel Programming | |||
Saving with date in filename | Excel Programming | |||
Save date in filename | Excel Programming |