Search results

  1. T

    Adding AD published network printers with VB

    Hi All, I am wondering if there is a quick and dirty way to pull a list of printers from Active Directory and then add one based upon user choice. I've had a look around and there seems to be two approaches either using DirectoryServices.DirectorySearcher or LDAP Connection but I'm struggling...
  2. T

    Resolved Rename a Mapped Drive

    Amazing, first snippet resolved it thank you although I note your point about the Char vs String. When I defined DriveLetter as a string I actually got "'Object variable or With block variable not set.'" which I think indicates that the variable is empty. Again, not sure why but alas you have...
  3. T

    Resolved Rename a Mapped Drive

    Hmm so think I was a bit premature in my excitement...... Seems if I hard-code the drive letter it works a treat but if I use the variable I get 'Conversion from type 'UShort' to type 'Char' is not valid.' error which I don't understand as the variable (DriveLetter) is defined as a Char and...
  4. T

    Resolved Rename a Mapped Drive

    Thank you so much for quick reply and help. This has done the job (works perfectly) and below is the full code if anyone is interested... Imports System.Runtime.InteropServices Public Class Form1 Public Declare Function GetLogicalDriveStrings Lib "kernel32" _ Alias...
  5. T

    Resolved Rename a Mapped Drive

    Hi Guys, I am not proficient in VB although but can hack my away around from time to time. At the moment, I am trying to write a very basic app that will allow a user to select a shared drive from a list and then click a button to map it. I have got this working quite nicely but despite...
Top Bottom