• I want to put a Windows Metafile into a PDF.

    Problem: my PowerBuilder code produces a PDF which is empty.

    Is there a return code from DrawMetaFile? If not, how do I know it worked?

    Any suggestion on API calls to load a Windows Metafile prior to calling DrawMetaFile?

    I used a PowerBuilder picture, similar to the Visual Basic example, but, unfortunately, the output PDF does not have the picture in it.

    Thank you.

    Victor

    • Offizieller Beitrag

    Can you change the code to save the metafile inmto a file and use DrawBitmapFile to export it. This would make it possible to reproduce any export problem, and makes itmpossible to check if the meatfile was empty.

    exporting a metafile usually does not require a StartPage before (and no EndPage after) since the page dimension will be loaded from the metafile.

    Julian Ziersch

  • Hi,
    I tried using DrawBitmapFile, but it returns 0 and there is no picture on the output PDF.

    This happened for both my test Visual Basic and PowerBuilder programs.

    Maybe the problem is that I'm using the demo.

    If I purchase the product, will DrawBitmapFile work for "large" WMF files? For example, suppose there are 100 pages, will it work?

    If so, this would be a welcome alternative for printing datawindows to PDF. Currently, we use another product, which uses a Windows Printer Driver. This causes complications with permissions, Group Policies (user is not allowed to install a printer driver), and the ever-changing rules for printer drivers on each new OS.

    Thank you.