about SHCNE_NETUNSHARE

about SHCNE_NETUNSHARE

Post by zmni » Fri, 27 Jun 2003 20:02:24



When I Use SHChangeNotifyRegister to register a notification, the
SHCNE_NETUNSHARE never posted though I unshare the folder.
And the more, If I share/unshare folder in explorer, the folder's property
in my program is wrong.
Such as, though I unshared the folder through explorer, But in my program it
is still in shared status, It seemed the shell cache the attributes(I use
pFolder->getAtrributesOf to retrieve the atrribtes, no matter whether I
specify the SFGAO_VALIDATE flags).

why????
help.

 
 
 

about SHCNE_NETUNSHARE

Post by Amir » Sat, 28 Jun 2003 15:09:23


Quote:> When I Use SHChangeNotifyRegister to register a notification, the
> SHCNE_NETUNSHARE never posted though I unshare the folder.

You will recieve SHCNE_NETSHARE for both sharing and unsharing events.

Quote:> And the more, If I share/unshare folder in explorer, the folder's property
> in my program is wrong.
> Such as, though I unshared the folder through explorer, But in my program
it
> is still in shared status, It seemed the shell cache the attributes(I use
> pFolder->getAtrributesOf to retrieve the atrribtes, no matter whether I
> specify the SFGAO_VALIDATE flags).

Yeh, something like this. We get old info using if we share/unshare a folder
through Win Explorer, and get updated info if we do this from our
application. To get this problem solved, you have to use Network Managment.
See help on "NetShareEnum(...)" in MSDN.