CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6
  1. #1
    Join Date
    Jan 2011
    Posts
    10

    Visual Basic 2008 Search Network For Printers IP addresses

    i am trying to find a code that will do a search and find the ip address of any printer on the network with a ip address?

    Please help thank you

  2. #2
    Join Date
    Jan 2006
    Location
    Fox Lake, IL
    Posts
    15,007

    Re: Visual Basic 2008 Search Network For Printers IP addresses

    Import Import System.Drawing.Printing namespace in your application, and something like this to add to listbox:

    Code:
    private void Form1_Load (sender as object , e as System.EventArgs)
    
    for each printer in PrinterSettings.InstalledPrinters
      printersList.Items.Add (printer.ToString()
    next
    David

    CodeGuru Article: Bound Controls are Evil-VB6
    2013 Samples: MS CODE Samples

    CodeGuru Reviewer
    2006 Dell CSP
    2006, 2007 & 2008 MVP Visual Basic
    If your question has been answered satisfactorily, and it has been helpful, then, please, Rate this Post!

  3. #3
    Join Date
    Jan 2011
    Posts
    10

    Re: Visual Basic 2008 Search Network For Printers IP addresses

    i dont want it to search for printers installed on my pc....i want it to search for printers that have a ip address even if there not installed on a pc...kinda like a ip range scanner

  4. #4
    Join Date
    Jan 2006
    Location
    Fox Lake, IL
    Posts
    15,007

    Re: Visual Basic 2008 Search Network For Printers IP addresses

    What would it scan for, if it's not connected? If you mean a network printer, then you'd have to query the network for available printers.
    David

    CodeGuru Article: Bound Controls are Evil-VB6
    2013 Samples: MS CODE Samples

    CodeGuru Reviewer
    2006 Dell CSP
    2006, 2007 & 2008 MVP Visual Basic
    If your question has been answered satisfactorily, and it has been helpful, then, please, Rate this Post!

  5. #5
    Join Date
    Jan 2011
    Posts
    10

    Re: Visual Basic 2008 Search Network For Printers IP addresses

    a computer is on a network that has printers installed on it.

    The computers ip is 192.168.1.120

    printer a is 192.168.1.233
    printer b is 192.168.1.235
    etc etc

    the print drivers are not installed on the computer

    i would like to have a program run a search on the network and find all of the printers that have a IP address. NOT Printers installed on the computer, just ANY printer that has a ip address.

    Kyocera Mita Printers and Konica Minolta Printers install wizard does this exact thing before installing a print driver.

  6. #6
    Join Date
    Jan 2006
    Location
    Fox Lake, IL
    Posts
    15,007

    Re: Visual Basic 2008 Search Network For Printers IP addresses

    Check the registry. It helps if you WROTE the entry that you are looking for.
    David

    CodeGuru Article: Bound Controls are Evil-VB6
    2013 Samples: MS CODE Samples

    CodeGuru Reviewer
    2006 Dell CSP
    2006, 2007 & 2008 MVP Visual Basic
    If your question has been answered satisfactorily, and it has been helpful, then, please, Rate this Post!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured