[原創(chuàng)]篩選連續(xù)合約的方法 [金字塔]
- 咨詢內(nèi)容:
以下內(nèi)容為程序代碼:
[此貼子已經(jīng)被作者于2011-1-22 19:08:35編輯過(guò)]
1 sub getcontinuouscontract()
2 dim marketname
3 set b=createobject("stock.block")
4
5 marketname=Array("SQ","DQ","ZQ","ZJ")
6
7 for i=0 to ubound(marketname)
8 n=marketdata.GetReportCount(marketname(i))
9 for j=0 to n-1
10 set myreport = marketdata.GetReportDataByIndex(marketname(i),j)
11 suffixlabel=right(myreport.label,2)
12 if suffixlabel="00" then
13 b.addstock marketname(i),myreport.label
14 end if
15 next
16 next
17
18 b.tosave "自選","自選股"
19 end sub - 金字塔客服:
以下內(nèi)容為程序代碼:
1 sub getcontinuouscontract()
2 dim block
3 dim market
4
5 set block=createobject("stock.block")
6
7 block.open "自選股",1
8
9 for i=0 to block.count-1
10 block.removeat(0)
11 next
12
13 market=array("SQ","DQ","ZQ","ZJ")
14
15 for i=0 to ubound(market)
16 n=marketdata.GetReportCount(market(i))
17 for j=0 to n-1
18 set report1=marketdata.GetReportDataByIndex(market(i),j)
19 if right(report1.label,2)="00" then
20 block.addstock market(i),report1.label
21 end if
22 next
23 next
24
25 block.tosave "自選","自選股"
26 msgbox "完成篩選連續(xù)合約"
27 end sub - 用戶回復(fù):
復(fù)制粘貼 無(wú)法通過(guò)
- 網(wǎng)友回復(fù): 去掉行號(hào)
相關(guān)文章
-
沒(méi)有相關(guān)內(nèi)容