CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3

Thread: Enviroment

  1. #1
    Join Date
    Jul 2005
    Posts
    22

    Enviroment

    I am trying to get the logical drives from the pc my app is run on, i tried this but it does not work what am i doing wrong?



    string[] strArray = new string[5] { Environment.GetLogicalDrives };

    thanks in advance

    Dave

  2. #2
    Join Date
    Oct 2002
    Location
    Timisoara, Romania
    Posts
    14,360

    Re: Enviroment

    GetLogicalDrives is a static method not a property, so you must use ().

    Try this:
    Code:
        String[] drives = Environment.GetLogicalDrives();
    Marius Bancila
    Home Page
    My CodeGuru articles

    I do not offer technical support via PM or e-mail. Please use vbBulletin codes.

  3. #3
    Join Date
    Jul 2005
    Posts
    22

    Re: Enviroment

    thanks

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