欢迎来到天天文库
浏览记录
ID:50846590
大小:31.50 KB
页数:7页
时间:2020-03-15
《获取ToolTipText内容VB源代码.doc》由会员上传分享,免费在线阅读,更多相关内容在工程资料-天天文库。
1、获取ToolTipText内容本篇内容提供一个获取ToolTipText内容的通用模块,并提供一个使用范例。请按以下四个步骤进行:一、把下面内容保存为Project1.vbpType=ExeForm=Form1.frmModule=mTray;mTray.basIconForm="Form1"Startup="Form1"HelpFile=""Title="Project1"ExeName32="GetToolTipText.exe"Command32=""Name="Project1"HelpCont
2、extID="0"CompatibleMode="0"MajorVer=1MinorVer=0RevisionVer=0AutoIncrementVer=0ServerSupportFiles=0VersionCompanyName="999-999-999"CompilationType=0OptimizationType=0FavorPentiumPro(tm)=0CodeViewDebugInfo=0NoAliasing=0BoundsCheck=0OverflowCheck=0FlPointCh
3、eck=0FDIVCheck=0UnroundedFP=0StartMode=0Unattended=0Retained=0ThreadPerObject=0MaxNumberOfThreads=1[MSTransactionServer]AutoRefresh=1二、把下面内容保存为Form1.frmVERSION5.00BeginVB.FormForm1BorderStyle=3'FixedDialogCaption="获取ToolTipText内容"ClientHeight=3510ClientL
4、eft=45ClientTop=330ClientWidth=3525LinkTopic="Form1"MaxButton=0'FalseMinButton=0'FalseScaleHeight=3510ScaleWidth=3525ShowInTaskbar=0'FalseStartUpPosition=3'窗口缺省BeginVB.CommandButtonCommand1Caption="获取xp“开始”按钮提示内容"Height=1215Left=840TabIndex=0Top=1920Widt
5、h=1815EndEndAttributeVB_Name="Form1"AttributeVB_GlobalNameSpace=FalseAttributeVB_Creatable=FalseAttributeVB_PredeclaredId=TrueAttributeVB_Exposed=FalseOptionExplicitPrivateDeclareFunctionFindWindowLib"user32"Alias"FindWindowA"(ByVallpClassNameAsString,By
6、VallpWindowNameAsString)AsLongPrivateDeclareFunctionFindWindowExLib"user32"Alias"FindWindowExA"(ByValhWnd1AsLong,ByValhWnd2AsLong,ByVallpsz1AsString,ByVallpsz2AsString)AsLongPrivateSubCommand1_Click()DimiAsLongDimsTrayListAsVarianti=FindWindow("Shell_Tra
7、yWnd",vbNullString)Ifi=0ThenExitSubi=FindWindowEx(i,0,"Button","开始")sTrayList=GetTrayList(i)Fori=0ToUBound(sTrayList)IfsTrayList(i)<>""ThenMsgBox"“开始”按钮提示内容是:"&sTrayList(i)EndIfNextEndSub三、把下面内容保存为mTray.basOptionExplicitPrivateDeclareFunctionOpenProcessL
8、ib"kernel32"(ByValdwDesiredAccessAsLong,ByValbInheritHandleAsLong,ByValdwProcessIdAsLong)AsLongPrivateConstPROCESS_VM_OPERATION=&H8PrivateConstPROCESS_VM_READ=&H10PrivateConstPROCESS_VM_WRITE=&H20PrivateConstPROCESS_ALL_AC
此文档下载收益归作者所有