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

    How can I "unhide" A file?

    I was wondering by pressing a command button how I could make some files visible..... you know how the box 'hidden' is checked in file properties how can i uncheck this on multiple files?


  2. #2
    Join Date
    May 1999
    Posts
    9

    Re: How can I "unhide" A file?

    im pretty new myself but i found this and it helped me with the same problem you will want to set your file to vbnormal to "unhide" it

    SetAttr Statement Example
    This example uses the SetAttr statement to set attributes for a file.

    SetAttr "TESTFILE", vbHidden ' Set hidden attribute.
    SetAttr "TESTFILE", vbHidden + vbReadOnly ' Set hidden and read-only
    ' attributes.

    Dir, GetAttr, and SetAttr Constants

    The following constants can be used anywhere in your code in place of the actual values:

    Constant Value Description
    vbNormal 0 Normal (default for Dir and SetAttr)
    vbReadOnly 1 Read-only
    vbHidden 2 Hidden
    vbSystem 4 System file
    vbVolume 8 Volume label
    vbDirectory 16 Directory or folder
    vbArchive 32 File has changed since last backup

    hunter



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