Quantcast
Channel: VFPX
Viewing all articles
Browse latest Browse all 3798

New Post: FoxBin2PRG handle records in DBFs

$
0
0
Hi Doug:

I've looked at your changes, and they look good! The only reason I haven't included this functionality from the beginning is that the main purpose of FoxBin2Prg is to be used as diff and merge tool, so the data is generally not used in this scenario.

But you give an idea that can serve for this purpose: I've added a new "run_AfterCreate_DB2" property that fires the indicated VFP program or procedure each time a DBF is converted to DB2, so when using FoxBin2Prg as object, this procedure receives the name of the cursor (which is open at this time) and the datasessionid, so anyone can make his own routine for exporting data. In your example you have used a manual construction of XML, other can use CURSORTOXML or even other implementations.

On version v1.19.19 I've added the opposite "run_AfterCreateTable" property, which indicated program or procedure is fired each time a DB2 is converted to DBF. In this case I know a developer that is using it for a personal backup system, to load the DBFs from external files. There is an example demo program on TESTS folder called "demo_hook_dbf.prg" showing how to use this functionality.

I think that having this possibility of calling an external program permits broader use cases that can be applied just when neccesary and not force to always do it.

Is this useful to your use case?

Viewing all articles
Browse latest Browse all 3798

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>