下面的语句你会编译吗?先谢过了!
以下截自某.BAS文件End Sub
Private Sub Main()
Dim strTemp As String
Dim ret As Long
Dim n As Integer
Screen.MousePointer = vbHourglass
DoEvents
strTemp = Environ$("PressID")
Select Case Len(strTemp)
Case 0
strPressID = "P000"
Case 1
strPressID = "P0" & strTemp
Case 2, 3
strPressID = "P" & strTemp
End Select
strLogFileName = App.Path & Replace$(strPressID, "P", "\Press") & ".log"
' strLogFileName = App.Path & "\Press" & Mid$(strPressID, 2, 3) & ".log"
strFactory = UCase$(GetSetting(App.Title, "GlobalConstant", "Factory", "AUBU"))
If strFactory <> "MIENT" Then strFactory = "AUBU"
SaveSetting App.Title, "GlobalConstant", "Factory", strFactory
User_Message vbNullString, FILE_MESSAGE
If App.PrevInstance = True Then
User_Message "Previous Instance of programm is loaded, programm terminated", FILE_MESSAGE
End
Else
' If Len(Dir(strLogFileName)) <> 0 Then
' If FileLen(strLogFileName) > 24000 Then ' max size of log-file 24 KByte
' If Len(Dir$(App.Path & "\log_old.txt")) <> 0 Then Kill App.Path & "\log_old.txt"
' Name strLogFileName As App.Path & "\log_old.txt"
' End If
' End If
烦请各位高手帮忙解释一下 十分感谢!