printers

How to get Printer Info in .NET?

不想你离开。 提交于 2019-12-17 02:12:14
问题 In the standard PrintDialog there are four values associated with a selected printer: Status, Type, Where, and Comment. If I know a printer's name, how can I get these values in C# 2.0? 回答1: As dowski suggested, you could use WMI to get printer properties. The following code displays all properties for a given printer name. Among them you will find: PrinterStatus, Comment, Location, DriverName, PortName, etc. using System.Management; ... string printerName = "YourPrinterName"; string query =

How can I locate all the network printers in the enterprise?

浪子不回头ぞ 提交于 2019-12-14 03:48:11
问题 When I go to Printers and Faxes dialog, I can click the Add a printer link, select Network Printer , then Find a printer in the directory . From there I get a dialog box which lets me find ALL printers in the enterprise. I need to find all the network printers with my code. How can I do this? Note that I am not talking about network printers that are connected to my PC, but all network printers in the enterprise (my workplace has almost 4000 printers). P.S. PrintServer().GetPrintQueues only

How I can get printer name from device and printers IShellFolder?

旧巷老猫 提交于 2019-12-14 03:42:50
问题 I'm getting system printers icons using code (only way I found - is to use IShellFolder ), now I want to connect them with InstalledPrinters, but problem is - I can`t find way to find real printer name (such as "\ServerName\PrinterName" ), with is different to display name of content of "Devices and printers" shell folder and only correct to use with PrinterSettings. The code I have use to retrive printer icons and printer captions in "Devices and printers" shell folder: Shell32.IShellFolder

Invoking UPnP actions

大兔子大兔子 提交于 2019-12-13 04:00:30
问题 I'm attempting to interact with a UPnP printer on my network. I can discover the printer, get the available services on it, and even get the list of actions available for a service. However, this is where I'm stuck. For example, there is an action GetPrinterAttributes and I know I need to create a http POST to send an envelop requesting the action, but I do no know what that looks like. I'm hoping someone can help point me to documentation or anything to get me going again. Based on other

Inserting a page Break in a text file by inserting FormFeed Character. Is this Universal solution?

可紊 提交于 2019-12-12 17:49:27
问题 Inserting a page Break in a text file by inserting FormFeed Character using Java. Is my solution universal or will it cause any problems? Sample Code: PrintWriter bof = response.getWriter(); // Obtained Writer from HTTP Response bof.write("Para 1"); // Write 1st Para to printWriter bof.write(new Character((char) 12).toString()); // Write Form Feed Character for Page Break bof.write("Para 1"); // Write 2nd Para to printWriter My Concerns: The Solution is working but below my 2 concenrs: Point

How to create virtual printer with iOS Simulator?

北城余情 提交于 2019-12-12 14:34:06
问题 In one of my application there is feature to print documents. I want to test this feature but I don’t have device, So I have to test on Simulator. With simulator how can I print documents. Do I need to connect physical printer or can I create virtual printer and test with it ? I am using Xcode 8.2.1 , iOS 10 and StarPrint iOS SDK 5.2.1 I have searched lot but I didn’t find which work for me. How can I do that ? I have referred below links : Where is printer simulator in Xcode 6 Here I cannot

Hide Android print dialog for Hp printers

梦想与她 提交于 2019-12-12 04:23:58
问题 I have developed an Android application which prints a photo using either PrintHelper or Hp mobile print SDK. However, when before the printing process, Android print Dialog comes up on the screen. How can I skip the android print dialog, when the application prints the photo ? I have already come across below questions. Briefly, the answers are "there is no way to do this." Print without print dialog Android Print from android without system dialog Is it possible to directly print content to

“Let Windows manage my default printer” is missing [closed]

守給你的承諾、 提交于 2019-12-12 03:06:51
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 3 years ago . Update: Based on down votes I got, I decided to explain why I am asking this question. I am writing a C# application that use the default printer. The problem is when printing in Windows 10 through my application, the default printer is not returned as expected. After some research, I found that it is a new

Connecting My Android app with wifi printer for printing bills

馋奶兔 提交于 2019-12-12 01:59:14
问题 I am trying to print a set of values through a wifi printer without internet.How to detect the list of wifi printers and connect to them.The tough part is how to start printing when the data is sent from mobile android app.Sample code will be very helpful. Note : we are not supposed to use any secondary applications and also it should not depend on printers from specific manufacturer.It should detect all the printers available through wifi and print through the selected printer. 来源: https:/

Multiple snmp open port

拟墨画扇 提交于 2019-12-11 19:33:41
问题 I have a problem with SNMP. I connect to SNMP with PHP using this code: <?php $session = new SNMP(SNMP::VERSION_1, "xxx.xxx.xxx.xxx", "public"); $fulltree = $session->walk("."); print_r($fulltree); echo "<br>"; $session->close(); ?> The code works perfectly, it isn't the problem. The problem is can I have more IPs that I need connect with SNMP. I have a firewall (ZyWALL), and can have 4 printers. The problem occurs because I can set the 161 port only at one printer, and not at all. How I can