Sub SJBC()
if application.ReceiveDataStatus=0 then application.ReceiveData(1)
Application.PeekAndPump
application.SendMessage(33882)
call application.Settimer(1,600000)
call application.Settimer(2,9000000)
Set Wrap = CreateObject("DynamicWrapper")
Wrap.Register "user32.dll","FindWindowA","i=ss","f=s", "r=l"
Wrap.Register "user32.dll","FindWindowExA","i=llss","f=s", "r=l"
Wrap.Register "user32.dll","SendMessageA","i=lull","f=s", "r=l"
h = Wrap.FindWindowA("#32770","數據接收")
tab=Wrap.FindWindowExA(h,0,"SysTabControl32","")
TCM_SETCURFOCUS=4912
WM_SETFOCUS=7
WM_KEYDOWN=256
WM_KEYUP=257
BM_CLICK=245
Wrap.SendMessageA tab,TCM_SETCURFOCUS,2,0
h1=Wrap.FindWindowExA(h,0,"#32770","自定義補數據")
cb=Wrap.FindWindowExA(h1,0,"ComboBox","")
Wrap.SendMessageA cb,WM_SETFOCUS,0,0
Wrap.SendMessageA cb,WM_KEYDOWN,VK_DOWN,0
Wrap.SendMessageA cb,WM_KEYUP,VK_DOWN,0
bt=0
bt=Wrap.FindWindowExA(h1,0,"Button","開始補充")
Wrap.SendMessageA bt,BM_CLICK,0,0
if bt<>0 then todayhas=1
End Sub
這個代碼好像是實現自定義的補數據功能,怎么實現批量補數據,只需要補充期貨類數據就可以了
我在自定義補充數據時候,,添加品種時,我選擇所有的期貨合約,當出現移倉時出現新的合約時,請問是否還需要手動添加新的合約進去,他才回自動補充新的合約數據
不需要了