DC_Workarea2excel - error Freezepanes
Posted: Tue Dec 13, 2022 8:24 am
Hi, Roger,
Sometimes my clients have problem, when creating xls table with function DC_Workarea2excel.
Only on some computers, and on more than one row header.
I found solution, in function DC_Workarea2excel where is row :
oSheet:Application:ActiveWindow:FreezePanes:=.T.
i replace it with this :
This is example, when number of header rows are variable.
No need upgrade _dcfunct.prg, I create copy of DC_Workarea2excel to other function DC_Workarea2excel2, and use it in my source.
Maybe someone had problems with it too.
Viktor
Sometimes my clients have problem, when creating xls table with function DC_Workarea2excel.
Only on some computers, and on more than one row header.
I found solution, in function DC_Workarea2excel where is row :
oSheet:Application:ActiveWindow:FreezePanes:=.T.
i replace it with this :
Code: Select all
oSheet:Application:ActiveWindow:FreezePanes := .F.
if nHeadRows=1
oSheet:Rows("2:2"):Select
elseif nHeadRows=2
oSheet:Rows("3:3"):Select
elseif nHeadRows=3
oSheet:Rows("4:4"):Select
else
oSheet:Rows("2:2"):Select
endif
oSheet:Application:ActiveWindow:FreezePanes := .T.
No need upgrade _dcfunct.prg, I create copy of DC_Workarea2excel to other function DC_Workarea2excel2, and use it in my source.
Maybe someone had problems with it too.
Viktor