Rob van der Woude's Scripting Pages
Powered by GeSHi

Source code for defprn2k.kix

(view source code of defprn2k.kix as plain text)

  1. ; Check if OS is Windows 2000/XP
  2. If Split( "@DOS", "." )[0] = 5
  3. 	$2KKey = "HKEY_CURRENT_USER\Software\Microsoft\"
  4. 	$2KKey = $2KKey + "Windows NT\CurrentVersion\Windows"
  5. 	$ArrayPRN = Split( ReadValue( $2KKey,"Device" ), "," )
  6. 	? "Default printer = " + $ArrayPRN[0]
  7. 	? "Printer port    = " + $ArrayPRN[2]
  8. Else
  9. 	? "DefPRN2K.kix,  Version 1.01 for Windows 2000"
  10. 	? "Display default printer"
  11. 	?
  12. 	? "Usage:  KIX32  DEFPRN2K.KIX"
  13. 	?
  14. 	? "Written by Rob van der Woude"
  15. 	? "http://www.robvanderwoude.com"
  16. EndIf
  17. ?
  18.  

page last uploaded: 2016-12-15, 11:20