[求助]关于表格控件指定数据源为SQL查询临时表,帮帮忙,错在哪里
为单位编的一个人事管理系统 ,希望能通过左边的TREEVIEW控件选 择部门后,在右边的表格控件内自动显示本部门相应人员信息,窗口图片如下
" border="0" />
treeview NodeClick 事件中有:
SELECT sequence as 序号, name as 姓名, sex as 性别, birthdate as 出生年月, nation as 民族, record as 学历,;
partydate as 入党时间, workdate as 参加工作时间 from database\tblpeople where Unitid=val(subs(node.key,2)) ;
into cursor tmppeople order by sequence
thisform.Grid1.RecordSource='tmppeople'
thisform.grid1.refresh
表单运行结果 右边表格控件变成空白
" border="0" />
SQL查询 语句后加BROW命令,查询结果无问题
" border="0" />
请各位大大帮看一下,问题出在哪里,谢谢!!!!!
[[it] 本帖最后由 txfantong 于 2008-9-2 11:27 编辑 [/it]]