SetAttrributes

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • andrew vos

    #1

    SetAttrributes

    I need to find out how to set fileAttributes for a given file.
    Apparently FileInfo.SetAtt ributes works but i dont know how to define
    FileAttributes.
    For example how do i make a file Hidden, and readOnly.


  • Peter Rilling

    #2
    Re: SetAttrributes

    Bit operators.

    FileAttribute.H idden & FileAttribute.R eadOnly

    I also think that you can just add the values together (Hidden + ReadOnly).

    "andrew vos" <andrewvos@andr ewvos.za.net> wrote in message
    news:O#55M2F5DH A.1636@TK2MSFTN GP12.phx.gbl...[color=blue]
    > I need to find out how to set fileAttributes for a given file.
    > Apparently FileInfo.SetAtt ributes works but i dont know how to define
    > FileAttributes.
    > For example how do i make a file Hidden, and readOnly.
    >
    >[/color]


    Comment

    Working...