Clarion ProScan Help

No File Handling Option

No File Handling Option

Previous topic Next topic  

No File Handling Option

Previous topic Next topic  

ProScan now allows you to not use any of the standard file handling options.  This allows you to "roll your own" method of dealing with file storage and placement during processing.  Just select the Do Not Manage option on the ProScan Link button:

 

clip0052

 

Then when you generate the code for the first time, look at the MODULE view of the procedure where you added the button you will see that comments have been generated into the code like this

 

clip0053

 

Just go to the ProScan Link button, right click and drop into the embeds as shown here:

 

clip0054

 

Use the Before Procedure Call and the After Procedure Call embeds to enter your code that sets the GROUP data that needs to be passed to ProScan as well as any file handling operations.

 

ProScan expects you to set these values in the Before embed:

 

FileIsFromBlob      BYTE                                   ! Set to TRUE (1) if the TIFF is loaded from a Blob

FileToLoad          STRING(255)                            ! The FULL Filename of the tiff ( example:  MyFile.TIF )

FileStoragePath     STRING(255)                            ! The path where the file is loaded ( including a trailing backslash )

 

 

Then in the After embed you can do your own file storage handling and read data (if needed) from the values that the template mapped in place for you after the procedure call:

 

        !Map data returned from ProScan to local variables (if any are set in template)

         !Set the name to the return

DemoE:YourFileName = PSPath.GetFullFileName( PSRETURN:TheFileName )

DemoE:YourFilePath = PSPath.GetFilePath( PSRETURN:TheFileName )

DemoE:LastModifyDate   = CLIP( PSRETURN:TheFileDate )

DemoE:FileSize   = CLIP( PSRETURN:TheFileSize )

DemoE:LastModifyTime   = CLIP( PSRETURN:TheFileTime )

DemoE:PageCount   = CLIP( PSRETURN:ThePageCount )

DemoE:CompressionUsed   = CLIP( PSRETURN:CompressionUsed )

 

 

This option gives you the control that you need to do anything that you need to do.