fdbozzo / foxbin2prg

Visual FoxPro 9 Binary to Text and Text to Binary converter. Replacement for SCCText(X) and TwoFox that is bi-directional (Text is editable)
https://vfpx.codeplex.com/wikipage?title=FoxBin2Prg
MIT License
59 stars 35 forks source link

Support for VFP Advanced #82

Closed CHamlinPNP closed 2 years ago

CHamlinPNP commented 2 years ago

📝 Provide a description of the new feature

What is the expected behavior of the proposed feature? What is the scenario this would be used? At the moment when it generates the binary...it create FoxPro 9 compiled objects. How about adding the support to allow for it to create VFP Advanced objects?

If you'd like to see this feature implemented, add a 👍 reaction to this post.

DougHennig commented 2 years ago

Not sure what you mean. There isn't a difference between a VFP and VFPA binary file (e.g. SCX or VCX).

CHamlinPNP commented 2 years ago

Code generated by VFP9 is NOT compatible to code generated by VFPA. You have to recompile the objects in order for them to work properly. They are not compatible compiled object codes between them.

DougHennig commented 2 years ago

Oh, you mean the compiled code. In that case, rebuild FoxBin2PRG.exe from its project using VFPA.

lscheffler commented 2 years ago

@CHamlinPNP

Code generated by VFP9 is NOT compatible to code generated by VFPA. You have to recompile the objects in order for them to work properly. They are not compatible compiled object codes between them.

What you can do is, run the prg instead of the exe. Parameters are the same. This is what I do. Note, the various files included in the EXE must be available, but this is just the folder where Thor installs.
see

lscheffler commented 2 years ago

@CHamlinPNP
Yes you are right, the binaries in an VCX depend on the version of VFP where COMPILE CLASSLIB runs. So the FoxBin2PRG.EXE that ships with Thor is - for common use - compiled in VFP9SP2. If you run this exe, it runs under VFP9, and uses theVFP9 BUILD IN COMPILE CLASSLIB that you can run from any VFP EXE.
IOW FoxBin2PRG just fils the text parts of the VCX / SCX and calls COMPILE CLASSLIB to create the binary stuff that belongs into the library. There are three solutions:

  1. Recompile foxBin2PRG.EXE as Doug suggests
  2. Use the PRG instead of the EXE
  3. recompile anything after FoxBin2PRG-recreating the binary in your version of VFP. FoxBin2PRG recreates the binary files, possibly not the binary codes in this files.

What I can do is add an option to not run COMPILE CLASSLIB in FoxBin2PRG, so you must recompile. Let me know if this would be a help to your problem.

lscheffler commented 2 years ago

@CHamlinPNP
Sorry for being a bit slow, last month was awkward. Still not on top of my mind. In the last message I mentioned an option to suppress COMPILE CLASSLIB (etc). This option exists all the time. Using parameters:

FOXBIN2PRG.EXE <cFileSpec.Ext> [cType [cTextName [cGenText [cDontShowErrors [cDebug [cDontShowProgress [cOriginalFileName [cRecompile [cNoTimestamps [cCFG_File [cOutputFolder] ] ] ] ] ] ] ] ] ] ]
*..
cRecompile:        Indicates recompile ('1') the binary once regenerated. You can specify a Path too (ie, the project one)

For parameters try do e:\se\vfpx\foxbin2prg\foxbin2prg.prg WITH '?' or do e:\se\vfpx\foxbin2prg\foxbin2prg.prg WITH '-interactive'
There is currently no switch in config file foxbin2prg.cfg.

I have thought a bit over the possibilities.

  1. I can add a new switch to the config, working the same way as the parameter above.
  2. I can trick FoxBin2Prg to compile under a different version of VFP then it's actual. Basically the compiles are all in compileFoxProBinary, so one could call a different VFP to do the compile in an external process rather internal. One need to figure out the location of the VFP9.exe of the Version needed, but this is available in HKLM\SOFTWARE\WOW6432Node\Microsoft\VisualFoxPro. It would need an additional switch in config file to tell FoxBin2Prg what to do. Anyway, if you run FoxBin2Prg.exe out of the IDE using DO ìt must be compiled to the version of VFP it runs in. If you just run one version of VFP all the time this might be overkill, then a recompile will do.

Please let me know what you think to do with this problem, or if recompile solves it for you, so the issue could be closed.

creacionesintegrales commented 2 years ago

Actualmente trabajo con VFPA, PlasticSCM y foxbin2prg. Tuve que recompilar el foxbin2prg para que me funcionase. Adjunto las herramientas que estoy utilizando sin inconvenientes.

plasticscm-tools-for-visual-foxpro-9-master.zip

La configuración de las mismas en Plastic la hago siguiendo el instructivo de Fernando.

https://fdbozzo.blogspot.com/2014/03/instalacion-de-plasticscm-paso-paso.html

DougHennig commented 2 years ago

Translated to English using Google Translate:

I currently work with VFPA, PlasticSCM and foxbin2prg. I had to recompile the foxbin2prg to make it work for me. I attach the tools I am using seamlessly.

plasticscm-tools-for-visual-foxpro-9-master.zip

The configuration of the same in Plastic I do following the instructions of Fernando.

https://fdbozzo.blogspot.com/2014/03/instalacion-de-plasticscm-paso-paso.html