我是这样做的: (1)从GRID控件拖放到表单上(假设名为grid1),设置其属性: Recordsourcetype为0---表 (2)为表单的active过程编程 pp=getfile(″dbf″,″″,″″,2) if empty(pp) thisform.release return endif use &pp *选定所需的表 n=fcount() thisform.grid1.columncount=n thisform.grid1.recordsource=pp for i=1 to n thisform.grid1.columns(i).header1.caption=field(i) endfor use (3)再在表单加上插入、删除、添加、完成等几个按钮,就可构成较完善的输入界面,实现数据的整体输入。 |
|