那如果我想打印的语句有两种情况呢! adodc1.connectstring="dsn=pb" adodc1.commandtype=adcmdtext if text4.text<> "" then adodc1.recordsource="select * from box where 编号='text4.text '" else adodc1.recordsource="select * from box where 序号=max " 这段代码写在哪儿?
private sub cmbshow_click() adodc1.connectstring="dsn=pb" adodc1.commandtype=adcmdtext adodc1.recordsource="select * from box where 编号='26 '" set rptbox.datasource=adodc1.Recordset rptbox.show end sub
adodc1.commandtype=adcmdtext
if text4.text<> "" then
adodc1.recordsource="select * from box where 编号='text4.text '"
else
adodc1.recordsource="select * from box where 序号=max "
这段代码写在哪儿?
adodc1.connectstring="dsn=pb"
adodc1.commandtype=adcmdtext
adodc1.recordsource="select * from box where 编号='26 '"
set rptbox.datasource=adodc1.Recordset
rptbox.show
end sub
但rptbox的datamember应该在哪儿设呢!
rptbox里的那些需要显示数据库数据的textbox应该怎样进行绑定呢?