Batch for automatic printer mapping between 2 rooms

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Message
Author
Hans
Posts: 2
Joined: 16 Mar 2012 03:31

Batch for automatic printer mapping between 2 rooms

#1 Post by Hans » 16 Mar 2012 03:49

Hello @ all

1. I'm not very good in English ... and batches :S I hope you can unerstand it..

I need a batch, that can distinguish between 2 IP-Ranges and automatically selcet the correct standard printer. I have to distinguish in Ip Ranges and not computernames.

Details:


First Room Ip Range 10.65.8.x
Printer First Room Ip : 10.65.8.199

Second Room IP Range 10.65.10.x
Printer Second Room Ip : 10.65.10.199



Thanks !

Regards
Hans

jeb
Expert
Posts: 1055
Joined: 30 Aug 2007 08:05
Location: Germany, Bochum

Re: Batch for automatic printer mapping between 2 rooms

#2 Post by jeb » 16 Mar 2012 07:41

Hi Hans,

I see two problems.

1. Determin the own IP
2. Change the default printer

1. Can be solved with parsing the results of ipconfig (with a FOR /F Loop)
2. Can be solved with reg.exe, but you need to find the correct registry-keys (Google or search with RegEdit)

jeb

Hans
Posts: 2
Joined: 16 Mar 2012 03:31

Re: Batch for automatic printer mapping between 2 rooms

#3 Post by Hans » 16 Mar 2012 07:53

Kannst du mir das nun noch auf Deutsch erklären? :D

jeb
Expert
Posts: 1055
Joined: 30 Aug 2007 08:05
Location: Germany, Bochum

Re: Batch for automatic printer mapping between 2 rooms

#4 Post by jeb » 16 Mar 2012 08:05

Hallo Hans,

for question (and answers) in german you could try administrator.de
Für Fragen (und Antowrten) kannst du administrator.de ausprobieren.

jeb wrote:I see two problems.

1. Determin the own IP
2. Change the default printer

1. Can be solved with parsing the results of ipconfig (with a FOR /F Loop)
2. Can be solved with reg.exe, but you need to find the correct registry-keys (Google or search with RegEdit)


Du hast zwei Problem zu lösen
1. Die eigene IP Adresse bestimmen
- kann man mit IPConfig erhalten und mit einer FOR/F Schleife untersuchen

2. Den Standard-Drucker umstellen
- Wird man über die Registry lösen können, muss man halt nur den Registry-Schlüssel kennen (oder Google fragen)

jeb

Post Reply