Page 1 of 1 1
Topic Options
#134972 - 2005-03-04 06:00 PM default printer
Toga Offline
Fresh Scripter

Registered: 2005-03-03
Posts: 8
hello,
When i try to set a Default Printer with this code it doesn't work... what I do wrong?:
Code:
IF INGROUP("ALL_users")
Deltree ("HKEY_Current_User\printers\connections")
AddPrinterConnection("\\testserver\CanoniR2.3")
setdefaultprinter("\\testserver\HPColorL")
AddPrinterConnection("\\testserver\HPColorL")


ENDIF



with kind regards,

Tom

Top
#134973 - 2005-03-04 06:42 PM Re: default printer
maciep Offline
Korg Regular
*****

Registered: 2002-06-14
Posts: 947
Loc: Pittsburgh
Have you tried adding the printer before you try to make it the default.

And saying "it doesn't work" isn't very helpful. So in the future, try to explain what doesn't work.
_________________________
Eric

Top
#134974 - 2005-03-04 08:05 PM Re: default printer
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
Also, the two functions do not use the same name. One uses the printer name and the other, the share name.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#134975 - 2005-03-05 11:56 AM Re: default printer
Toga Offline
Fresh Scripter

Registered: 2005-03-03
Posts: 8
Quote:

Also, the two functions do not use the same name. One uses the printer name and the other, the share name.



Hello Les that was the problem! thx

Tom

Top
Page 1 of 1 1


Moderator:  Glenn Barnas, NTDOC, Arend_, Jochen, Radimus, Allen, ShaneEP, Ruud van Velsen, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 484 anonymous users online.
Newest Members
Sir_Barrington, batdk82, StuTheCoder, M_Moore, BeeEm
17886 Registered Users

Generated in 0.049 seconds in which 0.02 seconds were spent on a total of 12 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org