7,763
社区成员
发帖
与我相关
我的任务
分享
Public Str, txt1, exe1
Public Function ReadFile(ByVal FileName As String) As String
Dim objStream As Object
Set objStream = CreateObject("ADODB.Stream")
With objStream
.Type = 2
.mode = 3
.Open
.Charset = "UTF-8"
.LoadFromFile FileName
ReadFile = .ReadText
.Close
End With
End Function
Private Sub Form_Load()
Text1.Text = ReadFile(App.Path & "\AUTOMARK.ini")
txt = Split(Text1, "<txt>")
If Right(txt(1), 1) = "\" Then txt1 = Left(txt(1), Len(txt(1)) - 1) & "\TEMP.BTF" Else txt1 = txt(1) & "\TEMP.BTF"
exe = Split(Text1, "<exe>")
If Right(exe(1), 1) = "\" Then Text2.Text = Left(exe(1), Len(exe(1)) - 1) Else Text2.Text = exe(1)