Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Checking directory rights
Message
De
23/03/2006 17:17:28
Neil Mc Donald
Cencom Systems P/L
The Sun, Australie
 
 
À
23/03/2006 12:55:37
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Divers
Thread ID:
01105494
Message ID:
01107200
Vues:
20
Hi,
Thanks, that should work.

The problem is that we are interfacing to a government dept using PKI software supplied by them (Not very well written) which creates temp files in it's own %PROGRAMFILES% directory, and if the rights change, the software does not work, no errors.

I just need to check that the correct rights are set in their software directory prior to transmission, and if not set the required rights.

>>What I am looking for is the best way (via code) of sensing the change and resetting to the required rights, any ideas.
>
>First of all it is not recommended to modify files in %PROGRAMFILES% subfolders. (This means where your program is installed)
>Because by default users have no permission to write there. (And this is good - they cannot damage program files).
>You must use Application Data folder in the user's profile to save application data like databases, settings and so on.
>
>Anyway, the best (and easiest) way to check permissions is to try them.
>If you cannot create file in some folder then you have no create/write permissions.
>
>The NTFS permissions could be set via API. I found some example code in VB.
>http://support.microsoft.com/default.aspx?scid=kb;EN-US;295004
>I don't know is there some VFP example available.
Regards N Mc Donald
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform