求vf常用命令

来源:学生作业帮助网 编辑:作业帮 时间:2024/11/25 19:55:55
求vf常用命令
xT]OA+>-m #Z`bYlf(o`A 1$1Ec"1̶L) '}{=wHxI—l0(o%2kL +oLonA{Wp[M?g}|Ͱ"&C96YǷ1,28呡KsFk6vi,C@T)Q:-ch] 㢶#(

求vf常用命令
求vf常用命令

求vf常用命令
1、文本框的CLICK事件,使显示的内容具有复选框的效果
if thisform.check1.value=1
thisform.text1.fontbold=.t.
else
thisform.text1.fontbold=.f.
endif
if thisform.check2.value=1
thisform.text1.fontitalic=.t.
else
thisform.text1.fontitalic=.f.
endif
if thisform.check3.value=1
thisform.text1.fontunderline=.t.
else
thisform.text1.fontunderline=.f.
endif
2、统计每个客户或每个职员的订单数和平均金额
do case
case thisform.optiongroup1.value=1
SELECT Orders.客户号,COUNT(*) as 订单数,;
AVG(Orders.金额) as 平均金额;
FROM orders;
GROUP BY Orders.客户号 into cursor t1
thisform.grid1.recordsourcetype=1
thisform.grid1.recordsource="t1"
thisform.refresh
case thisform.optiongroup1.value=2
SELECT Orders.职员号,COUNT(*) as 订单数,;
AVG(Orders.金额) as 平均金额;
FROM orders;
GROUP BY Orders.职员号 into cursor t1
thisform.grid1.recordsourcetype=1
thisform.grid1.recordsource="t1"
thisform.refresh
endcase
3、函数使用[计算]命令按钮的CLICK事件代码
a=thisform.text1.value
do case
case a>5
thisform.text2.value=cos(a)-2
case a>=5 and a=85 and Grade.课程号 = thisform.combo1.value;
into array p1
thisform.text1.value=p1
select count(*) from grade where 成绩>=60 and 成绩100 or a=85
b="优秀"
case a>60 and a