Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Foxpro and Win2000
Message
From
05/12/2000 22:10:11
 
 
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00446642
Message ID:
00449764
Views:
18
>>I Have an idea for you involving the use of a small piece of code to dig through a project and try to force a rewrite of component files:
><snip>
>Thank you Ed,
>I have run the code but unfortunately it does not seem to change anything. The forms still refuse to drop onto Adaptec CD writer, but if I put those same forms into a winzip archive and then unzip them, they work OK.

Cut and paste didn't copy the * in the wildcard, so you might want to try it again. If I get abitious, I'll write something that uses CopyFile()

In the meantime, try adding this after the 2nd SHFileOperation() call:
DECLARE INTEGER _flushall IN MSVCRT
? _flushall()

Or:

Function FlushBuffersOfT
CLOSE ALL
CLEAR ALL
LOCAL aFileSet[1,5], nNumFiles, nFile, nFH, cChar, lResource, cResource
lResource = SET('RESOURCE') = 'ON'
cResource = SET('RESOURCE',1)
SET RESOURCE OFF
nNumFiles = ADIR(aFileSet,FULLPATH(CURDIR()) + '*.??T')
FOR nFile = 1 TO nNumFiles
   IF aFileSet[nFile,2] > 0
      nFH = FOPEN(FULLPATH(CURDIR()) + aFileSet[nFile,1],2)  && buffered write
      =FSEEK(nFH,-1,2)                                       && before EOF
      cChar = FREAD(nFH,1)                                   && read a char
      =FSEEK(nFH,-1,2)                                       && before EOF
      =FWRITE(nFH,cChar)                                     && write a char
      =FFLUSH(nFH)                                           && flush buffer
      =FCLOSE(nFH)                                           && close
   ENDIF
ENDFOR
DECLARE INTEGER _flushall IN MSVCRT
IF lResource
   SET RESOURCE TO (cResource)
   SET RESOURCE ON
ENDIF
RETURN _flushall()
This is off the top of my head again, so watch it.
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform