Over the years I have used VB to have some projects and feelings! <1> a, so that the display window defined Public Const HWND_BOTTOM = 1Public Const HWND_NOTOPMOST = -2Public Const HWND_TOP = 0Public Const HWND_TOPMOST = -1 function Public Sub MakeWindowAlwaysTop (hwnd As Long) SetWindowPos hwnd at the forefront of the screen, HWND_TOPMOST, 0, 0 , 0, 0, SWP_NOMOVE Or SWP_NOSIZEEnd Sub MakeWindowAlwaysTop Me.hwnd two calls, the media player control functions WindowsMediaPlayer 1, volume WindowsMediaPlayer1.settings.volume = WindowsMediaPlayer.settings.volume 15 (-15) 2, left and right channels WindowsMediaPlayer. Settings.balance = -100 (left sound) WindowsMediaPlayer.Settings.balance = 0 (right) Third, mouse hide definition public declare function showcursor lib "user32" (Byval Bshow as long) AS long call showcursor 0 four, access text file Module1 stencil defined Public Declare Function GetPrivateProfileInt Lib "kernel32" Alias "GetPrivateProfileIntA" (ByVal lpApplicationName As String, ByVal lpKeyName As String, ByVal nDefault As Long, ByVal lpFileName As String) As LongPublic Declare Function GetPrivateProfileString Lib "kernel32" Alias "GetPrivateProfileStringA" ( BYVAL LPKEYNAME AS ANY, BYVAL LPDEFAULT AS String, ByVal lpReturnedString As String, ByVal nSize As Long, ByVal lpFileName As String) As Long Function Public Function GetNumberFromINIFile (ByVal Path As String, ByVal AppName As String, _ByVal KeyName As String, ByVal defaultVal As Long, ByVal INI_filename As String) As LONGDIM NUM As Longif Strcomp (Right (Path, 1), "/") THEN PATH = PATH & "GetNumberFrominiFile = DefaultValGetNumberfrominiFile =
GetPrivateProfileInt (AppName, KeyName, defaultVal, INI_filename) End FunctionPublic Function GetStringFromINIFile (ByVal Path As String, ByVal AppName As String, _ByVal KeyName As String, ByVal defValue As String, ByVal INI_filename As String, Optional ByRef sLen As Integer) As StringDim returnStr As StringDim charCopy As LongDim summy As LongcharCopy = 1024If StrComp (Right (Path, 1), "/") Then Path = Path & "/" 'Get the filename in inifileGetStringFromINIFile = Trim (defValue) returnStr = String (charCopy, Chr (0 )) summy = GetPrivateProfileString (AppName, KeyName, "", returnStr, charCopy, INI_filename) GetStringFromINIFile = StrConv (MidB (StrConv (returnStr, vbFromUnicode), 1, summy), vbUnicode) sLen = summyEnd Function call str = GetStringFromINIFile (App. Path, "Output" & i, "msg", rtyrtyrty, curpath & "/input.ini")'getstringfrominifile is the string 'getNumberFrominifile in the text file is the data in the text file. The pop-up of the CD-ROM drive and Reclaim Define Public Declare Function McIndstring Lib "Winmm.dll" Alias "McIndstringa" (Byval LPSTRCOMMAND AS STRING, B yVal lpstrReturnString As String, ByVal uReturnLength As Long, ByVal hwndCallback As Long) As Long function 1, the pop-up Public Function Eject_CD_TRAY () As BooleanDim rv As LongDorv = mciSendString ( "Set cdaudio door open wait", 0 &, 0, 0) DoEventsLoop While rv <> 0Eject_CD_TRAY = TrueEnd Function2, recovered Public Function Load_CD_TRAY () As BooleanDim rv As LongDorv = mciSendString ( "Set cdaudio door closed wait", 0 &, 0, 0) DoEventsLoop While rv <> 0Load_CD_TRAY = TrueEnd Function call call Load_CD_TRAY VI. System delay definition public declare function gettickcount lib "kernel32"