question from newbie

Please support our Visual Basic 4 / 5 / 6 advertiser: Programming Forums - DaniWeb Sister Site
Reply

Join Date: Jun 2007
Posts: 3
Reputation: ndutz is an unknown quantity at this point 
Solved Threads: 0
ndutz ndutz is offline Offline
Newbie Poster

question from newbie

 
0
  #1
Jun 29th, 2007
hi, i am a newbie...

would anybody please to tell me,
how is the codes, to directly changing windows default printer,
from within visualbasic code,
without poping: windows select printer dialog box

best regards
ndutz
Reply With Quote Quick reply to this message  
Join Date: Jan 2007
Posts: 319
Reputation: DenisOxon is an unknown quantity at this point 
Solved Threads: 15
DenisOxon's Avatar
DenisOxon DenisOxon is offline Offline
Posting Whiz

Re: question from newbie

 
0
  #2
Jun 29th, 2007
Do you wish to change default printer or just use another ? How will program know which printer to pick if you don't put dialog box up ?

If your application changes users default printer without them knowing they could be very annoyed.

Denis
Last edited by DenisOxon; Jun 29th, 2007 at 9:02 pm.
Reply With Quote Quick reply to this message  
Join Date: May 2007
Posts: 538
Reputation: choudhuryshouvi is an unknown quantity at this point 
Solved Threads: 49
choudhuryshouvi's Avatar
choudhuryshouvi choudhuryshouvi is offline Offline
Posting Pro

Re: question from newbie

 
0
  #3
Jun 30th, 2007
Look, "Epson Ex-1000" is the default printer for windows in all versions. It is the printer which anybody can use even if they don't physically have any printer installed to see the print preview. Now if you wish to change this printer setting to something else you've to first tell windows to what printer you want to switch on. You can write code to extract all printer names which are currently installed in a combo box. After that you select a printer and change to it. In this case you don't need to display the printer dialog box.
Reply With Quote Quick reply to this message  
Join Date: Aug 2006
Posts: 20
Reputation: shasur is an unknown quantity at this point 
Solved Threads: 1
shasur shasur is offline Offline
Newbie Poster

Re: question from newbie

 
0
  #4
Jun 30th, 2007
All your PRinters are listed in the printers collection.

The VB6.0 code would be

Sub Select_A_PRinter()

Set Printer = Printers("Your Printer Name")

End Sub
Reply With Quote Quick reply to this message  
Join Date: Jan 2007
Posts: 319
Reputation: DenisOxon is an unknown quantity at this point 
Solved Threads: 15
DenisOxon's Avatar
DenisOxon DenisOxon is offline Offline
Posting Whiz

Re: question from newbie

 
0
  #5
Jun 30th, 2007
Originally Posted by choudhuryshouvi View Post
Look, "Epson Ex-1000" is the default printer for windows in all versions. .

Which country are you referring to ? We don't get this as default in any version of windows, except maybe Windows 3.0

Please fill me in.

Denis
Reply With Quote Quick reply to this message  
Join Date: Jun 2007
Posts: 3
Reputation: ndutz is an unknown quantity at this point 
Solved Threads: 0
ndutz ndutz is offline Offline
Newbie Poster

Re: question from newbie

 
0
  #6
Jul 1st, 2007
thank you...
i try and i get:
runtime error 13
type mismatch
Reply With Quote Quick reply to this message  
Join Date: Jun 2007
Posts: 3
Reputation: ndutz is an unknown quantity at this point 
Solved Threads: 0
ndutz ndutz is offline Offline
Newbie Poster

Re: question from newbie

 
0
  #7
Jul 1st, 2007
Set Printer = Printers("Your Printer Name")

thank you...
i try and i get:
runtime error 13
type mismatch
Reply With Quote Quick reply to this message  
Join Date: May 2007
Posts: 538
Reputation: choudhuryshouvi is an unknown quantity at this point 
Solved Threads: 49
choudhuryshouvi's Avatar
choudhuryshouvi choudhuryshouvi is offline Offline
Posting Pro

Re: question from newbie

 
0
  #8
Jul 2nd, 2007
Originally Posted by DenisOxon View Post
Which country are you referring to ? We don't get this as default in any version of windows, except maybe Windows 3.0

Please fill me in.

Denis

Belonging to some other country than you are won't change windows default printer from "Epson Ex-1000" to something else. It is the universal settings from Microosft which a few people know. You can only use this printer setting to make the print preview option functional while working in some text editors,word processors like notepad,wordpad,Ms-Word,etc. but cannot print anything. Windows doesnot automatically detect and install this printer. To install this printer setting you have to install all associated files from the installation disk of the version of windows which you've installed. To install this printer you can follow these steps :-

Insert the windows installation disk->goto control panel->printer->add new printer->select appropriate port->then from the printer selection screen click Epson from manufactures list and then select Epson Ex-1000 from printers list. After this clicking OK will install all necessary files for this printer onto your computer. Now if you goto print preview option of any text editor such as notepad you can see that option is working. I assume that you should know without installing a printer you cannot use the print preview option within any text editors. This printer setting is recommended for users who donot physically have any printer installed with their machine.

Hope this will clear your idea.

Regards
Shouvik
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:




Views: 1264 | Replies: 7
Thread Tools Search this Thread



Tag cloud for Visual Basic 4 / 5 / 6
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC