我試驗了下,dbgrid.additem('游标值')
會出錯, 說additem 是bad function
我的遊標這樣寫的, 不對阿
string v_c1,v_c2, v_c3,v_c4,v_c5,v_c6
integer v_c7
int i
i=1
DECLARE c CURSOR for
select huoqu.xuehao_id,huoqu.kecheng_id,huoqu.xueqi,huoqu.jiaoshi,huoqu.jiaoshi_id,huoqu.xuefen
from huoqu
where huoqu.xuehao_id=:stu_no ;
//{USING TransactionObject};
open c;
fetch c into :v_c1,:v_c2,:v_c3,:v_c4,:v_c5,:v_c7;
do while sqlca.sqlcode = 0
dw_1.additem('v_c1')
dw_1.additem('v_c2')
dw_1.additem('v_c3')
dw_1.additem('v_c4')
dw_1.additem('v_c5')
dw_1.additem('v_c7')
i=i+1
fetch c into :v_c1, :v_c2,:v_c3,:v_c4,:v_c5,:v_c7;
loop
close c;
請指點下 謝謝~