?? utilities.bas
字號:
Attribute VB_Name = "modUtilities"
Public SDECon As New MapObjects2.DataConnection
Public bSDEConnected As Boolean
'將窗體居中
Public Sub CenterForm(frm As Form)
frm.Top = (Screen.Height - frm.Height) \ 2
frm.Left = (Screen.Width - frm.Width) \ 2
End Sub
'選中TextBox中的文字
Public Sub HiliteText(Ctrl As Control)
Ctrl.SelStart = 0
Ctrl.SelLength = Len(Ctrl)
End Sub
'將文件的完全路徑分割為文件名和路徑
Sub SplitPath(pathName As String, dirName As String, fileName As String)
'尋找最后一個"\",以分割文件名和路徑
' in the path
Dim nCurPos As Integer, nLastPos As Integer
Do
nLastPos = nCurPos
nCurPos = InStr(nCurPos + 1, pathName, "\")
Loop Until nCurPos = 0
If nLastPos = 0 Then Exit Sub
Dim fname As String
dirName = Left(pathName, nLastPos - 1)
fname = Right(pathName, Len(pathName) - nLastPos)
fileName = Left(fname, Len(fname) - 4)
End Sub
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -