//首记录 procedure TSecSettingToolButtonClick(Sender: TObject); begin datasourceDataSetFirst; end; //上记录 procedure TSecSettingToolButtonClick(Sender: TObject); begin datasourceDataSetPrior; end; //下记录 procedure TSecSettingToolButtonClick(Sender: TObject); begin datasourceDataSetNext; end; //尾记录 procedure TSecSettingToolButtonClick(Sender: TObject); begin datasourceDataSetLast; end; //关闭窗体 procedure TSecSettingToolButtonClick(Sender: TObject); begin close; end; //保存记录 procedure TSecSettingToolButtonClick(Sender: TObject); begin //检查科目代码是否已输入 if dbeditText= then begin showmessage(科目代码不允许为空值); exit; end; datasourceDataSetPost; SetToolBar(false); end; //取消操作 procedure TSecSettingToolButtonClick(Sender: TObject); begin datasourceDataSetCancel; SetToolBar(false); end; //查询数据并显示 procedure TSecSettingBitBtnClick(Sender: TObject); begin adoqueryClose; adoquerySQLClear; adoquerySQLAdd(select * from 科目表 where (科目代码 like %+editText+%)and); adoquerySQLAdd((科目名称 like %+editText+%)and(科目类别 like %+editText+%)); adoqueryOpen; end; [] [] [] |