Public Class DirMaker
Public Function GenerateSaveDirString(ByVal Month As String, ByVal Day As String, ByVal Year As String) As String
Dim Ret As String
Dim Mon As String = ConvertMonth(Month)
Ret = "C:\Imported\" & Mon & "-" & Year & "\" & Day & "\"
If Not System.IO.Directory.Exists(Ret) Then
System.IO.Directory.CreateDirectory(Ret)
End If
Return Ret
End Function
Public Function ConvertMonth(ByVal Month As String) As String
Select Case Month
Case 1 : Return "Jan"
Case 2 : Return "Feb"
Case 3 : Return "Mar"
Case 4 : Return "Apr"
Case 5 : Return "May"
Case 6 : Return "Jun"
Case 7 : Return "Jul"
Case 8 : Return "Aug"
Case 9 : Return "Sept"
Case 10 : Return "Oct"
Case 11 : Return "Nov"
Case 12 : Return "Dec"
End Select
End Function
End Class