Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Is there a function which returns Windows system directo
Message
 
To
19/03/1998 13:53:32
Rene Van Den Berg
Infertility Database Systems Ltd
Islington, United Kingdom
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00085737
Message ID:
00085740
Views:
33
>I would like to write a file to the Windows system directory after the expiry date of the demo which should disable my application (limited time demo version). Is there a way of finding out the name of the Windows system directory?

Rene,

Here's the declaration and how to use it:
DECLARE INTEGER GetSystemDirectory IN Win32API;
  STRING @c_ReturnBuffer, INTEGER n_BufferSize
lcbuffer = SPACE(265)
lnbufflen = LEN(lcbuffer)
lnbufflen = GetSystemDirectory(@lcbuffer, lnbufflen)
IF lnbufflen > 0
  lcbuffer = LEFT(lcbuffer, lnbufflen)
ENDIF
hth,
George

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

Click here to load this message in the networking platform