PDF file not created by SDK on 64-bit Windows 7 as non-Admin
Posted: Tue Dec 07, 2010 3:54 pm
I have a problem in my application, which is written in PowerBuilder, when using the SDK to programatically create PDF files on 64-bit Win7. Unless the application is run as Administrator, everything seems to go OK (no functions return error messages or throw exceptions) but the file is never created. This does not seem to happen on 32-bit computers or with other versions of Windows, when running as a normal (non-Admin) user.
novaPDF support says they are not aware of any other problems like this, and that this works for them (though they don't have PowerBuilder so can't test my code directly) but I'm wondering whether any other users on this forum may have seen similar problems.
What happens more specifically is that I register for the various messages that the SDK can send, in particular the NOVAPDF2_FILESAVED
message. The window I specified receives this message, but the file I specified to be saved (by setting the options Save Folder and Save File using the COM object's SetOptionString2 method) has not been created. There are no differences in the code I execute on any version of Windows, or depending on whether the user is running as Admin or not. And of course, I'm not trying to save to a folder that the non-Admin user doesn't have write permission on.
I also just found the references about how to run with 32-bit programs (which my app is) on 64-bit windows in the KnowledgeBase (which I'm pretty sure Support had never pointed me to), and I tried it with those changes - adding /RegisterWin32COM to the command line for the installer, and calling options.LicenseApplication("SPLWOW64.EXE") before the print job. They didn't change this problem for me at all.
Any bright ideas? This is very irritating to my program's users who have this problem, because they have to remember to run as Admin when they are going to be using one of the features in my app that creates PDF files (which is generally not every time they use the app). Thanks.
novaPDF support says they are not aware of any other problems like this, and that this works for them (though they don't have PowerBuilder so can't test my code directly) but I'm wondering whether any other users on this forum may have seen similar problems.
What happens more specifically is that I register for the various messages that the SDK can send, in particular the NOVAPDF2_FILESAVED
message. The window I specified receives this message, but the file I specified to be saved (by setting the options Save Folder and Save File using the COM object's SetOptionString2 method) has not been created. There are no differences in the code I execute on any version of Windows, or depending on whether the user is running as Admin or not. And of course, I'm not trying to save to a folder that the non-Admin user doesn't have write permission on.
I also just found the references about how to run with 32-bit programs (which my app is) on 64-bit windows in the KnowledgeBase (which I'm pretty sure Support had never pointed me to), and I tried it with those changes - adding /RegisterWin32COM to the command line for the installer, and calling options.LicenseApplication("SPLWOW64.EXE") before the print job. They didn't change this problem for me at all.
Any bright ideas? This is very irritating to my program's users who have this problem, because they have to remember to run as Admin when they are going to be using one of the features in my app that creates PDF files (which is generally not every time they use the app). Thanks.