Results 1 to 6 of 6

Thread: [RESOLVED] Drive1.Drive

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Sep 2009
    Location
    Lost in thought
    Posts
    349

    Resolved [RESOLVED] Drive1.Drive

    Hi
    How do I put ''Network connections'' in to Drive1 list box.
    From msdn
    Drive Property


    Returns or sets the selected drive atrun time. Not available atdesign time.

    Syntax

    object.Drive [= drive]

    The Drive property syntax has these parts:

    Part Description
    Object Anobject expression that evaluates to an object in the Applies To list.
    Drive Astring expression that specifies the selected drive.


    Remarks

    The valid drives for the Drive property include all drives present in or connected to the system when the control is created or refreshed at run time. The default setting of the Drive property is the current drive.

    When reading this property setting, the selected drive is returned in one of the following formats:

    Floppy disks — "a:" or "b:", and so on


    Fixed media — "c: [volume id]"


    Network connections — "x: \\server\share"
    When setting this property:

    Only the first character of the string is significant (the string isn't case-sensitive).


    Changing the setting for the Drive property invokes a Change event.


    Selecting a drive that isn't present causes an error.


    Setting this property also regenerates the drive list, providing a way in code to track network connections added since the control was created.
    If the FileName property is set to a qualified network path without a drive designation, the value of the Drive property is a zero-length string (""), no drive is selected, and the ListIndex property setting is –1.

    Note The Drive property returns a different value from the ListIndex property, which returns the list box selection.
    But nun of the ''Network connections'' in ''My Network Places'' lodes in to Drive1 list box
    Last edited by 5ms?; May 24th, 2010 at 08:49 PM.

  2. #2
    Next Of Kin baja_yu's Avatar
    Join Date
    Aug 2002
    Location
    /dev/root
    Posts
    5,989

    Re: Drive1.Drive

    I dont think the DriveList control can show network connections. Are you sure you are not reading an article applicable to VB.Net and not VB6?

  3. #3

  4. #4

    Thread Starter
    Hyperactive Member
    Join Date
    Sep 2009
    Location
    Lost in thought
    Posts
    349

    Re: Drive1.Drive

    I added the article.
    Yes it's from ''MSDN Library Visual Studio 6.0''.

  5. #5

    Thread Starter
    Hyperactive Member
    Join Date
    Sep 2009
    Location
    Lost in thought
    Posts
    349

    Re: Drive1.Drive

    Quote Originally Posted by RhinoBull View Post
    I think you have to map those network connections from Tools (menu) > Map Network Drive so they appear in your windows explorer as drives.
    It solved the problem.
    Thank you RhinoBull.

  6. #6

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