p; ms.Close() End Try Try ''''启动新程序 System.Diagnostics.Process.Start(strUrl) ''''结束当前京城 Me.Dispose() Catch ex As Exception End Try End Sub Private Sub FrmMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load ''''显示是否配置 以及配置结果 Me.tb_myConfig.Text = reanConfig(Application.ExecutablePath) If SeekPostion(Application.ExecutablePath) = 0 Then Me.l_res.Text = "该程序没有被配置过!" Else Me.l_res.Text = "该程序已经被配置过了!" End If End Sub Function SeekPostion(ByVal strPath As String) As Integer Dim ip As Integer = 0 ''''位置 Dim ms As IO.FileStream Dim br As IO.BinaryReader Try ms = New IO.FileStream(strPath, IO.FileMode.Open, IO.FileAccess.Read) br = New IO.BinaryReader(ms) ''''读取文件 Dim b() As Byte = br.ReadBytes(ms.Length) Dim ic As Integer For i As Integer = 0 To b.Length - 5 ic = i ''''这里检查标志,就是上面连续写2个 vbcrlf vbcrlf If b(ic) = 13 And b(ic + 1) = 10 And b(ic + 3) = 13 And b(ic + 4) = 10 Then ip = ic Exit For End If Next Catch ex As Exception 上一页 [1] [2] [3] 下一页 [系统软件]为什么iexplore.exe在打开网页时CPU使用会100%? [VB.NET程序][初学VB.net].exe 的版本命名问题! [Delphi程序]读一读Scktsrvr.exe的源程序 [Delphi程序]将WAV文件做到EXE文件的方法及注意事项 [VB.NET程序]FLASH工具的秘密——SWF2EXE [其他]java.exe出错错误分析 [Access]能否编译mdb文件到exe文件?
|