Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Making a file Read-Only
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00322772
Message ID:
00322892
Views:
19
>Thanks George and Randy. I'd rather directly use the API since it really isn't complicated at all. I assume that directly calling the API will be faster than creating a COM object, right?

I haven't done any testing in this area (and don't intend to either), but it is a logical assumption.

>However, you got me interested into the WSH. Does it come with Win95, 98, NT, 2000, other software? I got an NT4WS SP4 here and the CREATEOBJECT call worked, but how much can I assume on this? Also, anywhere I can find a reference (properties, methods, etc)? I looked on MS' web site not long ago for this but all I found was text saying that WSH is so great but I could not find anything useful! :(

Ed Rauh wrote up a terrific FAQ (FAQ#7885) on this subject. It can be found (for now) under Reports/What's New in the last 5 days. He's far more comprehensive in his FAQ than I could ever be. That'll tell you everything about where to get more information.

As you may know, I love mucking about with the API. However, there are reasons why, in some case, I'd recommend the WSH. Simply put, it can significantly reduce the amount of code I have to maintain. If the speed penalty (if there is one) is not significant, I'd go with the WSH. There are cases, however, where I'd use the API even though the same functionality can be found in it. For example, and this is a stretch, if it were absolutely necessary that I need the exact amount of total space or free space on a drive, I'd use the API. This would be because neither VFP's SYS(2020)/DISKSPACE() nor the WSH can give me what I need. I'll admit this is rather far-fetched, but it's the example that comes to mind most readily.
George

Ubi caritas et amor, deus ibi est
Previous
Reply
Map
View

Click here to load this message in the networking platform