资源描述:
《支持报表类型》由会员上传分享,免费在线阅读,更多相关内容在工程资料-天天文库。
1、1.支持的报表类型:支持Form、Group、Query、Tabular、Grid、Graph、Crosstab、Composite、N-Up类型的DW2.不支持的报表类型:不支持Lable、RichText、Ole类型的DW3.导出EXCEL调用函数说明:a)采用默认格式导出DataWindow到EXCEL:gf_dw_to_excel(datawindowadw_dw,stringas_filename)adw_dw为要导出的datawindow,as_filename为要导出的文件名(要包含路径)调用举例
2、:intli_rcstringls_path,ls_fileli_rc=GetFileSaveName("选择文件",ls_path,ls_file,"XLS",&"ExcelFiles(*.xls),*.xls,*.*")ifli_rc<>1thenreturnIntegerli_ret=1ifright(upper(ls_file),3)='XLS'thenli_ret=gf_dw_to_excel(dw_1,ls_path)endifReturnli_retb)采用定制格式导出DataWindow到EXC
3、EL:gf_dw_to_excel_parm(adw_dw,as_filename,n_excel_parmanv_parm)adw_dw为要导出的datawindow,as_filename为要导出的文件名(要包含路径),anv_parm为EXCEL导出参数对象调用举例:intli_rcstringls_path,stringls_file,stringls_currentdirli_rc=GetFileSaveName("选择文件",ls_path,ls_file,"XLS",&"ExcelFiles(*.
4、xls),*.xls,*.*")ifli_rc<>1thenreturnIntegerli_ret=1ifright(upper(ls_file),3)='XLS'thenn_excel_parmlnvo_parm//建立参数对象lnvo_parm=Createn_excel_parmlnvo_parm.ib_detail=cbx_detail.checkedlnvo_parm.ib_prompt_openfile=cbx_prompt.checked//调用gf_dw_to_excel_parmli_ret=
5、gf_dw_to_excel_parm(dw_1,ls_path,lnvo_parm)destroylnvo_parmendifReturnli_reta)采用默认格式导出DataStore到EXCEL:gf_ds_to_excel(datastoreads_ds,stringas_filename)说明参见gf_dw_to_excelb)采用定制格式导出DataStore到EXCEL:gf_ds_to_excel_parm(ads_ds,as_filename,n_excel_parmanv_parm)说明参
6、见gf_dw_to_excel_parmc)n_excel_parm说明:n_excel_parm是EXCEL导出的参数对象,各属性的说明如下:publicbooleanib_header=true//是否导出header带publicbooleanib_foreground=true//是否导出前景对象publicbooleanib_background=true//是否导出背景对象publicbooleanib_detail=true//是否导出detail带publicbooleanib_summary=
7、true//是否导出summary带publicbooleanib_footer=true//是否导出footer带publicbooleanib_group_header=true//是否导出组头publicbooleanib_group_trailer=true//是否导出组尾publicbooleanib_keep_band_height=true//是否保持band高度publicbooleanib_enable_merge_cells=true//是否合并excel格publicbooleanib_s
8、how_progress=true//是否显示进度窗口publicbooleanib_prompt_openfile=true//是否提示打开文件publicbooleanib_dynamic_horizontal=false//是否每行都动态展开横向布局(如果有字段的X和宽度每行不同,要设置为true)publicbooleanib_dynamic_grid=false//是否每行都