Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to change file attribut...
Message
From
28/11/2001 04:18:12
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00586467
Message ID:
00586821
Views:
19
Jean,
FYI WSH doesn't exist or enabled on all platforms. They might download and install though (happened to me and it was a pain in neck instructing the customer). For that reason I do not use WSH if I can create an API counterpart.
Cetin

>This way (using Scripting object) is realy new for me.
>It really cool! :)
>Thank you.
>
>>>I what to change the file attribute to read only.
>>>How do we do this again?
>>
>>You can use WSH
>>oFSO = CREATEOBJECT("Scripting.FileSystemObject")
>>oFile = oFSO.GetFile(lcfile) && lcfile is the name of the file
>>* Turn on the read-only bit
>>oFile.Attributes = BITOR(oFile.Attributes, 0x01)
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform