Category : Files from Magazines
Archive   : VOL10N22.ZIP
Filename : CDISK.PRG
* CDISK.PRG Contains CURDISK() UDF for Clipper S87
* Demonstrates use of CURDISK() Clipper UDF.
***********************************************************************
?
? "Current Disk Drive -> " + CURDISK()
?
RETURN
***********************************************************************
* CURDISK() - Get current disk drive letter. UDF for Clipper S87
***********************************************************************
FUNCTION CURDISK
PRIVATE xRetVal, xHandle1, xRow, xCol
xRow = ROW() && save cursor position, row
xCol = COL() && and column
RUN CD > TMP. && run "CD" redirected to a file
xHandle1 = FOPEN("TMP.",0) && open file
xRetVal = FREADSTR(xHandle1, 2) && read first 2 chars
xRetVal = IIF(":" $ xRetVal, xRetVal, "") && check for error
FCLOSE(xHandle1) && close file
ERASE TMP. && erase file
@ xRow, xCol SAY "" && restore cursor position
RETURN xRetVal
Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!
This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.
But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/