用VB来写看看: C- J& r% _) n3 g
- E: H+ j: y) ~9 b- A
8 h2 K8 k* C4 j% C- 9 [9 }2 u3 c9 J4 t# }' [
- if DATAPERIOD<>0 then
: g2 E @6 S. d - begin
+ x# [* V4 z: y- G$ j - DRAWTEXT(BARPOS=SYSPARAM(2)+10,1,'本指标只能用于分笔分析');
. @0 T+ Z2 z1 ]0 |5 [& L/ S1 ` - exit;& u! L& o. U4 c# X2 m
- end;+ D/ c$ {: X4 n9 Y
1 d( A) b% _8 T% u+ f. p- dd:=date; s. a: L; H6 r$ C
: d& u3 l- E* i( b) F: p; E. w- str:=NUMTOSTR(time,0)+';'+NUMTOSTR(v,0)+';'+NUMTOSTR(c,2);7 W1 x; i, l2 `; m( }/ Z g- A2 }% h
- for i=25 to 36 do
4 F! s% y. p6 G; Y: t( M - begin4 _% R6 C8 }1 O6 z, t0 S/ O$ m
- str:=str+';'+NUMTOSTR(DYNAINFO(i),2);
8 \, y6 e8 T3 t. n - end;, s, y4 t) X' L( Z% B4 E& I, w
& O8 }8 D5 ]* `, ^( _- <% g* H* Y5 \0 L- j: p
- vd1 = FFL.VarData("dd")+ `8 K# m9 j. M/ p" E& l7 D' Q
- vd2 = FFL.VarData("str")( g# M# z& q! ?% V" b( Z, x
- nFirst = FFL.VarStartIndex("dd")
* A1 k+ b- t/ ~7 d8 C
( {0 `. b4 z, G+ u$ l9 S- Set fso=CreateObject("Scripting.FileSystemObject")- g$ Z0 ^$ J' S6 D! i% {
- fn ="D:/fhdata/"+cstr(vd1(nFirst))+"data.txt"& F' H' Z" G5 ]" B
- 8 V/ m5 w5 H" t1 q/ A3 i: }
- Set f1 = fso.OpenTextFile(fn,8,True)
' E& c0 U) \) @5 E/ d3 i$ P% w# H - f1.writeline vd2" `3 r. L/ ~% N" C
- f1.close
5 `/ e& _' q S% @
! X f7 W; H7 [; Y* }- %>9 q! B" l5 a7 q% m$ H9 g! I, P s% R) H
- % ~& d+ C+ w1 h: W" n' a
- aa:time;
+ M) B: I5 B+ m0 Z - Show File Failed% x* a) u2 E- F" W1 r
1 `# ~# ~+ D9 j! a" M0 Z e Y- $ J1 _5 Z0 n# ~% ^( Y9 b; }
复制代码
: I3 z; T# g: c+ t: g |