1、不明白你要做什么;
2、简单一些的:
If Dir("c:\file\file.exe") <> "" Then
   msgbox "File exists!",vbInformation,"My MsgBox Title"
End If
3、这样:
    Dim varToday
    Dim strMyFormat As String
    
    varToday = Time
    strMyFormat = Year(varToday) & "," & Month(varToday) & "," & Day(varToday) & "," & Hour(varToday) & "," & Minute(varToday) & "," & Second(varToday)
    MsgBox strMyFormat, vbInformation, "Custom Format"
4、上面已经有了!

解决方案 »

  1.   

    3、更正如下:
        Dim varToday
        Dim strMyFormat As String
        
        varToday = Now
        strMyFormat = Year(varToday) & "," & Month(varToday) & "," & Day(varToday) & "," & Hour(varToday) & "," & Minute(varToday) & "," & Second(varToday)
        MsgBox strMyFormat, vbInformation, "Custom Format"
        strMyFormat = Format(varToday, "yyyy,mm,dd,hh,mm,ss")
        MsgBox strMyFormat, vbInformation, "Custom Format"
      

  2.   

    非常感谢edyang,上面的我都通过了测试。
    1的问题,我是想计算程序运行的时间,呵
    1秒钟时间加1啊。能不能帮帮我,谢谢。