- Luca Militello
- PowerBuilder
- Tuesday, 9 June 2020 09:35 AM UTC
Hi,
a problem occurred while migrating application to PB2017 R3 Build 1915 from PB12_5.
This is the scenario:
the application needs to set a specific printer before printing document. There could be many documents printing and everyone could have a different printer.
This operation is made by setting windows registry using the function RegistrySet(as_key, as_value, as_var) before printing the document
where
as_key = "HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows"
as_value = 'Device'
as_var = <printer name>
In PB12_5 and lower versions the application give no problem, even in Win10, but only in runtime.
In PB2017 or PB2019 (i download the trial of PB2019 to try with this version) it uses always the default printer even if it correctly set the 'Device' key with the right printer. Morover and apparently randomly, sometimes the application seems to work but the document not printed. This never happen with PB12_5 version.
From PB environment (Pb12_5, Pb2017 and PB2019) the 'Device' key is correctly set, but no way to print with specific printer (always uses default printer).
Someone could help me?
Thanks a lot
Luca
Find Questions by Tag
Helpful?
If a reply or comment is helpful for you, please don’t hesitate to click the Helpful button. This action is further confirmation of their invaluable contribution to the Appeon Community.