| Author |
Topic  |
|
|
LukasBurgi
Switzerland
Posts |
Posted - 04/22/2005 : 01:56:31 AM
|
Origin Version (Select Help-->About Origin): 7.5 Operating System: XP
I try to export pages to pdf files using the following lines
LayoutPage oLayoutPage = Project.Pages("..."); string strFileName = "D:\Test.pdf"; export_page_to_image(oLayoutPage, strFileName,"pdf", FALSE);
This works fine for simple pages, however, for more complex pages like a layout page containing several graphs with several layers each, some layers get lost during the export process. Oddly enough, when the Origin window is minimized during program execution (calling the routine from the Code Builder) the export works ok even in the case of complex pages. The problem only occurs when the Origin window is on the screen during execution.
Any advice is highly apprecitated. Lukas |
|
|
Mike Buess
USA
3037 Posts |
Posted - 04/25/2005 : 12:58:21 PM
|
I don't know why that happens but this might work...
LayoutPage oLayoutPage = Project.Pages("..."); HWND hwnd = GetWindow(OGW_MAIN); Window oWin(hwnd); oWin.ShowWindow(SW_MINIMIZE); // minimize the program window string strFileName = "D:\Test.pdf"; export_page_to_image(oLayoutPage, strFileName,"pdf", FALSE); oWin.ShowWindow(SW_NORMAL); // restore program window
Mike Buess Origin WebRing Member |
 |
|
|
LukasBurgi
Switzerland
Posts |
Posted - 04/26/2005 : 01:58:33 AM
|
Thanks Mike. This works fine and omits the problem. Lukas |
 |
|
| |
Topic  |
|
|
|