** create a binary script STRTOFILE("MESSAGEBOX('Hello World')","temp.prg") COMPILE temp.prg cBlob = FILETOSTR("temp.fxp") DELETE FILE temp.prg DELETE FILE temp.fxp ** test our function SECURESCRIPT(cBlob) *********************************** FUNCTION SECURESCRIPT(cBlob) cTempFile = ADDBS(SYS(2023))+SYS(2015)+".fxp" ** copy script to temp file nLen = STRTOFILE(cBlob, cTempFile) ** open file readonly to lock it hnd = FOPEN(cTempFile) ** check the file size to make sure it is OK IF FSEEK(hnd,0,2) = nLen ** execute it DO (cTempFile) ENDIF ** cleanup FCLOSE(hnd) DELETE FILE (cTempFile)