473,397 Members | 1,961 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

change paper size for a customized kiosk printer

I have a special printer , like Epson printer. I need to change paper size to Roll. The printer doesn't use spooler. I want to change from "CUSTOM VKP80 II" to
"VKP80 II Roll" But it didn't work.
I found only way to do it is using vbs. I could not find any way to do in in powershell.

Expand|Select|Wrap|Line Numbers
  1. strComputer = "."
  2. Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")
  3. Set colItems = objWMIService.ExecQuery("Select * from
  4. Win32_PrinterConfiguration",,48)
  5.  
  6. For Each objItem in colItems
  7. Wscript.Echo "PaperSize: " & objItem.PaperSize
  8. objItem.PaperSize = VKP80 II Roll
  9. objItem.Put_()
  10. Wscript.Echo "PaperSize: " & objItem.PaperSize
  11. Next
Jul 16 '14 #1
0 1164

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: anthony | last post by:
hello , is there any simple way to override control panel>printer and fax>printer paper size setting by c# or vb.net?I tried the Printing.PrinterSettings class , however it seems use for setting my...
0
by: Larry | last post by:
Hi my friends, I'm writing a small program to print a form. The form is on customer sized paper. I trying to use following code to change paper size, but it dosn't work. Why?? There's always an...
0
by: Anniech | last post by:
I use VB.NET to integrate with crystal report 9.0 to print a report with custom paper size (using Dot Matrix printer). I have already added a custom paper size in the printer server and set the...
0
by: william.reynolds | last post by:
I am producing reports (via Crystal XI) on a web server. I use a variety of paper sizes in Crystal to produce PDF output. In development everything works fine since I can change the paper size...
6
by: Brewtzaff | last post by:
Hello, I have a little problem to print my reports on custom sized paper. I got a db containing clubmembers, a query which selects only the needed infos to print out my membershipcards. My...
1
by: Anne DeBlois | last post by:
Hi, I want to programatically set the paper size of a print document. I created a class that inherits PrintDocument, so I can print some database records on 8" x 10" paper. I added this line...
1
by: heroscripts | last post by:
Does anyone know how to assign a value for user-defined paper size in VB6 Printer object at runtime or design time? In Windows OS you can easily do it through Printer Setup but how about in VB code?
0
by: Agnes | last post by:
my PC default printer is Hp LaserJet my invoice 's printer is Epson and with German Standford paper size I had already set the paper size & printer during Crystal report's designer's mode ...
3
by: brianflannery | last post by:
Greetings all! My problem is this. I've installed a new printer on my computer. This is the "default printer" for access. Now, some of my reports, which were working fine with the old printer,...
0
by: Amjad Hussein | last post by:
Hi Guys I have a small issue with page setup, you know that in page setup there is a printer paper, and drawing page, I know how to change the printer paper but I need also to change the drawing...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.