vb编写的程序判断其它程序获得和失去焦点
例如我用VB写的程序A.exe启动时调用Calc.exe(计算器)程序,如果Calc.exe已启动则Calc.exe获得焦点,否则启动Calc.exe,但A.exe要保持...
例如我用VB写的程序A.exe 启动时调用Calc.exe(计算器)程序,如果Calc.exe已启动则Calc.exe获得焦点,否则启动Calc.exe,但A.exe要保持在Calc.exe的前面,如果Calc.exe失去焦点则A.exe也失去焦点,就记事本的查找对话框一样的效果。
展开
2个回答
2011-07-02
展开全部
Private Declare Function icePub_activForm Lib "icePubDll.dll" (ByVal strFormTitle As String) As Integer
Dim a2 As Integer
Dim str1 As String
str1 = "计算器"
'窗体标题
a2 = icePub_activForm(str1)
Private Declare Function icePub_open Lib "icePubDll.dll" (ByVal strPath As String) As Integer
Dim a2 As Integer
a2 = icePub_open("calc.exe")
Dim a2 As Integer
Dim str1 As String
str1 = "计算器"
'窗体标题
a2 = icePub_activForm(str1)
Private Declare Function icePub_open Lib "icePubDll.dll" (ByVal strPath As String) As Integer
Dim a2 As Integer
a2 = icePub_open("calc.exe")
参考资料: http://bbs.icese.net/icepubdll/icePubDLL%bd%d2%c3%d820110702.pdf
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询