DeleteNovaPrinter does not delete NVL-file
Posted: Mon Jul 02, 2012 11:54 am
Hi there,
we are using novaPDF with temporary printers for the print jobs. We call AddNovaPrinter with dynamically created printer names. Then we add and adjust profiles to let novaPDF silently create the desired PDF file.
After waiting for NOVAPDF_EVENT_FILE_SAVED we call SetActiveProfile with the original default profile, DeleteProfile with the temporary profile and DeleteNovaPrinter to finally remove the printer itself.
But how can we get novaPDF to not only remove the printer object from the system but also the created settings file in c:\Users\<user>\AppData\Roaming\Softland\novaPDF\ ?
Regards,
Lars Wittenburg
PS: How come that SetActiveProfile for the original active profile name does not work properly in this scenario? We got the error "unknown profile" if we used it like in the example for "Temporary printer". By trial and error we found out that we have to call it directly after GetActiveProfile (and before SetActiveProfile for the new temporary profile). Only then we could set the original active profile back at the end and after that successfully remove our temporary profile.
we are using novaPDF with temporary printers for the print jobs. We call AddNovaPrinter with dynamically created printer names. Then we add and adjust profiles to let novaPDF silently create the desired PDF file.
After waiting for NOVAPDF_EVENT_FILE_SAVED we call SetActiveProfile with the original default profile, DeleteProfile with the temporary profile and DeleteNovaPrinter to finally remove the printer itself.
But how can we get novaPDF to not only remove the printer object from the system but also the created settings file in c:\Users\<user>\AppData\Roaming\Softland\novaPDF\ ?
Regards,
Lars Wittenburg
PS: How come that SetActiveProfile for the original active profile name does not work properly in this scenario? We got the error "unknown profile" if we used it like in the example for "Temporary printer". By trial and error we found out that we have to call it directly after GetActiveProfile (and before SetActiveProfile for the new temporary profile). Only then we could set the original active profile back at the end and after that successfully remove our temporary profile.