Go Back   Forum Care Forums > Development Reference Area > Visual Basic

Reply
 
LinkBack Thread Tools Display Modes
Shared file attribute
Old
  (#1)
will_456
Guest
 
Posts: n/a
Default Shared file attribute - 06-04-2007, 10:35 AM

Is there a way of checking whether a file has a shared file attribute. And
then can you change it to unshared.
I can't use my program to make a copy of a file because it produces an
error.
However if I set the attributes so it is not marked as shared on
installation (Inno setup installer) the program can make a copy of it.


   
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Re: Shared file attribute
Old
  (#2)
Dean Earley
Guest
 
Posts: n/a
Default Re: Shared file attribute - 06-04-2007, 10:35 AM

will_456 wrote:
> Is there a way of checking whether a file has a shared file attribute. And
> then can you change it to unshared.
> I can't use my program to make a copy of a file because it produces an
> error.
> However if I set the attributes so it is not marked as shared on
> installation (Inno setup installer) the program can make a copy of it.


The "Shared attribute" is not an attribute on the file, it is a counter
stored in the registry.
This counter will have absolutely no bearing on whether you can access
the file or not.

Try using process explorer at the time it fails to see what has the file
open and locked.

--
Dean Earley (EMAIL REMOVED)
i-Catcher Development Team

iCode Systems
   
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




Contact Us - Forum Care Forums - Archive - Top