bobbyforhire
Technical User
I am creating a program that grabs my security logs and then moves the event log into a folder.
Starts at C:\LOGS
then
C:\LOGS\NAMEOFSERVER
then
DATE
The issue i am running into is that i want to use the date but when you get the DATE it will show you 6/24/2008 when i need for it to be 6\24\2008. or even better 2008\6\24
example of code:
If fso.FolderExists("C:\LOGS") Then
Else
Set fldr = fso.CreateFolder("C:\LOGS\")
End If
If fso.FolderExists("C:\LOGS\" & Combo1.Text) Then
Else
Set fldr = fso.CreateFolder("C:\LOGS\" & Combo1.Text)
End If
If fso.FolderExists("C:\LOGS\" & Combo1.Text & Date) Then
MsgBox "yup date"
Else
Set fldr = fso.CreateFolder("C:\LOGS\" & Combo1.Text & "\" & Date)
End If
It will crash because of the date...anyone have a good way of getting this done? I have already tried day,month,year but that doesn't seem to work.
Starts at C:\LOGS
then
C:\LOGS\NAMEOFSERVER
then
DATE
The issue i am running into is that i want to use the date but when you get the DATE it will show you 6/24/2008 when i need for it to be 6\24\2008. or even better 2008\6\24
example of code:
If fso.FolderExists("C:\LOGS") Then
Else
Set fldr = fso.CreateFolder("C:\LOGS\")
End If
If fso.FolderExists("C:\LOGS\" & Combo1.Text) Then
Else
Set fldr = fso.CreateFolder("C:\LOGS\" & Combo1.Text)
End If
If fso.FolderExists("C:\LOGS\" & Combo1.Text & Date) Then
MsgBox "yup date"
Else
Set fldr = fso.CreateFolder("C:\LOGS\" & Combo1.Text & "\" & Date)
End If
It will crash because of the date...anyone have a good way of getting this done? I have already tried day,month,year but that doesn't seem to work.