printer-properties

Default printer settings are ignored

試著忘記壹切 提交于 2020-01-04 01:58:11
问题 Using Windows Print Spooler API's, we can print out XPS files. The problem is that the print spooler ignores the default printer settings . (We've given up on trying to apply printer settings. Default printer settings will just have to suffice.) For example... the printouts always come out in colour and on one paper per page, regardless of what the settings are set to in the control panel: black & white/colour, duplex/not duplex, multiple pages per sheet/single page per sheet. Other

Configure Virtual Printer Port Redirection

大憨熊 提交于 2019-12-18 13:49:09
问题 I need to configure a virtual printer port to redirect it to a external program(.exe file) through c# code. Right now I am able to install a virtual port with some customization(thanks to bghh code). The attached picture illustrates the requirement. Any help will be highly appreciated. 回答1: I found out solution to the above problem. All the printer ports registered on the system are listed in registry under the key " SYSTEM\ControlSet001\Control\Print\Monitors\Redirected Port\Ports " Values

ResetDC() does nothing (print spooler API's for Windows)

六月ゝ 毕业季﹏ 提交于 2019-12-11 13:35:02
问题 I've written wrapper classes for Windows' print spooler APIs, which work... mostly. The only thing that does not work is applying printer settings . First I call DocumentProperties() to successfully acquire and play with printer settings. Then I try to apply those settings using ResetDC() but nothing happens. The function takes a valid handle, and returns the same valid handle, meaning it should have applied the settings. But, nothing seems to have happened: the printouts are unaffected by

Get Printer Status Using SNMP OID

浪子不回头ぞ 提交于 2019-12-10 00:30:33
问题 I am working with SNMP in Android. I want to get Printer Status. I am using Snmp4Android.jar and OID 1.3.6.1.2.1.25.3.5.1.1 . Please refer this link Printer Status. SnmpActivity.java here public class SnmpActivity extends Activity { private static String ipAddress = "PrinterIP"; private static String port = "Port"; private static String oidValue = "1.3.6.1.2.1.25.3.5.1.1"; public static Snmp snmp; public static CommunityTarget comtarget; static PDU pdu; static OID oid; static VariableBinding

Get Printer Status Using SNMP OID

£可爱£侵袭症+ 提交于 2019-12-04 21:01:42
I am working with SNMP in Android. I want to get Printer Status. I am using Snmp4Android.jar and OID 1.3.6.1.2.1.25.3.5.1.1 . Please refer this link Printer Status . SnmpActivity.java here public class SnmpActivity extends Activity { private static String ipAddress = "PrinterIP"; private static String port = "Port"; private static String oidValue = "1.3.6.1.2.1.25.3.5.1.1"; public static Snmp snmp; public static CommunityTarget comtarget; static PDU pdu; static OID oid; static VariableBinding req; Button b; private static final String tag = "SNMP CLIENT"; @Override public void onCreate(Bundle

How can I invoke the dialog to set printer options manually?

会有一股神秘感。 提交于 2019-12-03 13:36:56
问题 I'm using WPF and need to let users set some print related options like printer and printer properties (e.g. papertray, landscape/portrait, duplex, etc). I'm aware of the PrintDialog class to get a PrintQueue and PrintTicket object. However I need to create I custom solution and can not show the PrintDialog. I manage to get the available PrintQueue objects and let users select a printer. I'm struggling with the printer properties. My question is: how can I show the dialog in which a user can

How can I invoke the dialog to set printer options manually?

天大地大妈咪最大 提交于 2019-12-03 03:46:50
I'm using WPF and need to let users set some print related options like printer and printer properties (e.g. papertray, landscape/portrait, duplex, etc). I'm aware of the PrintDialog class to get a PrintQueue and PrintTicket object. However I need to create I custom solution and can not show the PrintDialog. I manage to get the available PrintQueue objects and let users select a printer. I'm struggling with the printer properties. My question is: how can I show the dialog in which a user can set the printer properties for the selected PrintQueue (the dialog that is shown when a user clicks on

How to intercept data being sent to a printer?

心不动则不痛 提交于 2019-12-01 13:38:38
问题 I'm interfacing with an application that's sending a raw printer file to the default printer. This is the only thing it will do with the data. I need to get this file somehow so I can store it elsewhere instead. What would be the best way to do this? The best I've thought of is to write an app that listens to a specific port, and set the default printer to that port. Would this way work? Is there a better way? 回答1: I ran across and LDP implementation for Java that I'm going to modify and use.

Configure Virtual Printer Port Redirection

╄→гoц情女王★ 提交于 2019-11-30 10:58:05
I need to configure a virtual printer port to redirect it to a external program(.exe file) through c# code. Right now I am able to install a virtual port with some customization(thanks to bghh code). The attached picture illustrates the requirement. Any help will be highly appreciated. I found out solution to the above problem. All the printer ports registered on the system are listed in registry under the key " SYSTEM\ControlSet001\Control\Print\Monitors\Redirected Port\Ports " Values under these keys can be edited to get the desired result. Below is the code to edit it using c#. bool found =