SitePoint Sponsor

User Tag List

Results 1 to 3 of 3

Thread: how to check the directory attributes as readonly and hidden in C# winforms

  1. #1
    Non-Member shivanee's Avatar
    Join Date
    May 2007
    Posts
    86
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    how to check the directory attributes as readonly and hidden in C# winforms

    Hello all,

    I want to check whether the directory/folder attributes are set to readonly and hidden.

    So, how do I check this in the c# winforms 2003?

    If they are found to be readonly and hidden then I want to uncheck the readonly checkbox and hidden checkbox using c# winforms.

    I want to check it for the directory only and not for the files.

    Please help me?

    Thanks in advance.

  2. #2
    Non-Member shivanee's Avatar
    Join Date
    May 2007
    Posts
    86
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hello all,

    I just want to remove readonly and hidden attributes using the c# code of the directory an not the file.

    But, when I am unchecking the readonly checkbox manually by right clicking the folder ---> Properties, and uncheck the readonly attribute, it is not setting it i.e, when I again right click the forlder and goes into properties, it is showing it as readonly again.

    So, how Can I set this readonly manually as well as using the c# winform code?


    Please help me out
    Thanks in advance.

  3. #3
    SitePoint Author silver trophybronze trophy
    wwb_99's Avatar
    Join Date
    May 2003
    Location
    Washington, DC
    Posts
    10,424
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    Everything you ever wanted to know about manipulating files in .NET 1.1 can be found at http://msdn2.microsoft.com/en-us/lib...io(VS.71).aspx.

    Also, this string of questions sounds suspiciously like homework. We don't do homework here. If you don't understand the problem, ask your teacher. That is what they are there for.

Bookmarks

Posting Permissions

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