printing

how do i check if a printer is installed and ready using C#?

送分小仙女□ 提交于 2020-01-09 03:41:30
问题 How do i programmatically check if a printer is installed or not (and if there is one, how do i check if it is on and ready to use?) in C# using .NET 3.5 and Visual Studio 2008? Thanks in advance, 回答1: This snippet will retrieve information about installed printers: using System.Drawing.Printing; //... foreach (string printerName in PrinterSettings.InstalledPrinters) { // Display the printer name. Console.WriteLine("Printer: {0}", printerName); // Retrieve the printer settings.

Loop through an array php

那年仲夏 提交于 2020-01-08 09:32:05
问题 I have this array... how do you print each of the filepath and filename? What is the best way to do this? Array ( [0] => Array ( [fid] => 14 [list] => 1 [data] => Array ( [alt] => [title] => ) [uid] => 1 [filename] => trucks_10785.jpg [filepath] => sites/default/files/trucks_10785.jpg [filemime] => image/jpeg [filesize] => 143648 [status] => 1 [timestamp] => 1291424171 [nid] => 8 ) [1] => Array ( [fid] => 19 [list] => 1 [data] => Array ( [alt] => [title] => ) [uid] => 1 [filename] => school

How to pass reference to combobox?

瘦欲@ 提交于 2020-01-07 02:06:22
问题 This is a continuation from a previous post of mine: How to select a printer for entire job?, where I basically want to print a series of reports from a form in my Access database. Which refers to this help doc: https://msdn.microsoft.com/en-us/library/ee336132(v=office.12).aspx I'm trying to create the combobox with active printers in it in order to temporarily change the default printer for a series of documents. I'm tripped up on where it says "pass a reference to a ComboBox control"...

How to print PDF with Not default printer with code (VB Net)

时间秒杀一切 提交于 2020-01-06 20:23:32
问题 I´m trying to print a pdf file, there is no problem to print it with the default printer but when I want to do it with a secondary printer it still printing with the default one. This is my code: Dim MyProcess As New Process MyProcess.StartInfo.CreateNoWindow = False MyProcess.StartInfo.Verb = "print" 'HERE IS WHERE I WANT TO CHANGE THE PRINTER (BUT THIS COMMAND IS IGNORED) MyProcess.StartInfo.Arguments = "Canon MG3500 series" MyProcess.StartInfo.UseShellExecute = True MyProcess.StartInfo

Excel 365 Print Preview

╄→尐↘猪︶ㄣ 提交于 2020-01-06 20:18:09
问题 I'm using Excel 365 on Windows 7 Home 64bit. When I open Print Preview from the Excel user interface I get a window with options like this: https://www.flickr.com/photos/132482128@N08/21711947524/in/dateposted-public/ From this window I can preview the whole print file, make adjustments to margins, select the printer to use, etc. I would like to access this window and these options from VBA. However when I use: ActiveWorkbook.Sheets("SheetName").PrintOut Preview:=True or: ActiveWorkbook

Page breaks in SAPUI5

为君一笑 提交于 2020-01-06 18:06:09
问题 What is the best practice for creating specific page breaks in SAPUI5 and is it actually possible? Classical CSS atributes page-break-after and page-break-before doesn't seem to work in my case. For example, I have two sap.m.VBox elements and I attached them a CSS class which specifies page-break-after: always !important; when printing, but nothing happens. If I add * {overflow-x: visible !important; overflow-y: visible !important;} then it will break and continue to draw the content in next

64-bit Windows 7 fopen prn

你说的曾经没有我的故事 提交于 2020-01-06 14:22:53
问题 I am using my antique Borland Builder 5 with Windows 7 64-bit. fptr=fopen("\prn","wb") fails. "prn", "prn:" also fail. fptr=fopen("HP8 lj4","wb") succeeds. But doesn't print anything. The "HP8 lj4" is the name of a printer; in control panel, or via "net view hp8gig". The console command { print /D:"HP8 lj4" shopping.ln } says "shopping.ln is currently being printed" -- but doesn't print anything either. Of course I print things on that printer all the time. My beautiful ASCII TSE editor can

Am I correct in understanding that vector printing in SilverLight 5 will only work with a Postscript printer?

◇◆丶佛笑我妖孽 提交于 2020-01-06 13:56:49
问题 I had read some blogs about SilverLight 5 and find it hard to believe what I read! That even on Windows, SilverLight 5 will only do vector (high quality) printing to a postscript printer. (Also happened to XML Paper becoming the format that all print drivers understood on windows…) 回答1: I found Silverlight 5: Vector and Bitmap Printing for Reports and more to be quite helpful regarding PostScript printing in Silverlight 5. In particular: If your content or your printer doesn't support

How to find a paper size / printable size and set the header and footer on print?

≡放荡痞女 提交于 2020-01-06 09:04:18
问题 This is some what difficult me. My client require to print the data's with header and footer on each page. There is a chance to use a A4, A3, A5 and Landscape papers. How can i able to set the header and footer on each of the page? And how can i able to set a data length according to the page? is there a way to create print template? I am using underscore-template in Backbone . Any one suggest me a way please? 回答1: For your issue no difference which template engine you use. For doing

How to find a paper size / printable size and set the header and footer on print?

不问归期 提交于 2020-01-06 09:03:09
问题 This is some what difficult me. My client require to print the data's with header and footer on each page. There is a chance to use a A4, A3, A5 and Landscape papers. How can i able to set the header and footer on each of the page? And how can i able to set a data length according to the page? is there a way to create print template? I am using underscore-template in Backbone . Any one suggest me a way please? 回答1: For your issue no difference which template engine you use. For doing