I have an app in C5, Legacy, and I would like to convert it to C9.1 ABC. What tips, templates, and everything else do you recommend? In C5 I have TinTools, FM2 and some other templates.
I tried using Legacy2ABC, and I didn’t have much luck… maybe I didn’t understand how to use it. Any suggestions?
First step, convert Legacy to ABC in C5. Make sure it works (ABC version).
Second step, open C5 ABC in c9.1. Ensure you have all third-party templates installed in c9.
If you have difficulty with some templates working in later versions of Clarion, like DLL’s, removing the templates in C5 first, and then converting the app, would also be an approach worth looking at.
When ABC first shipped however many decades ago, probably C5, there was a program shipped with it - Legacy2ABC, which is what Thales used – that was designed to ease conversion of projects. One of the things it did was move stuff from the Legacy-type embeds to the appropriate ABC-type embeds. For whatever reason, the program was not included in later versions (like C6), AFAIK.
Long time ago, but my recollection is a bunch of things still ended up in embed points that no longer existed.
I believe some people worked on improving it later on (Bruce? Bo Schmitz?) but I don’t know if those are available.
Russell Eggen kindly created a 32 bit version of Legacy2ABC app. Russ passed away a few years back, but BobZ gave me permission to open source the 32 bit version which can be found here: msarson/Legacy2ABC: 32 bit Version of Legacy to ABC Convertor
There are forks of that work as well.
It was never a tool to get you 100% converted so there will be work to do afterward, but it will get you part of the way.
There are a few tools around, but none are perfect.
You can also just edit the TXA file and change the references of CLARION to ABC.
If you open TXA using both you’ll see what I mean.
I don’t think Tintools is available for later versions. I could be wrong.
The biggest problem are places where in legacy you surround an embed with, say an IF. In ABC those embed point can be in different methods and so it will all fail.
Its of no use, because I dont have the code anymore, but I had an app which editted the txa, rewrote the code from legacy to abc and moved embed code to the right embed.
C5 to c9 is a major upgrade because the threading model changed in c6. So that upgrade is significant. You woll need to refactor the use of all hlobal variables.
Legacy to ABC is a major upgrade because all embed code needs to be inspected, altered, and likely repositioned.
You’re not going to do them both at the same time. Do one first, then the other. Frankly id do c5 legacy to c9 legacy first, because that gets you into a modern ide etc. (I guess youre happy with c9, its only a few major versions off the pace.)
Actually changing the app from Legacy to ABC is trivial, export to TXA , replace CLARION with ABC and create a new app from TXA. Thats the fast part. Then comes a lot of work converting the code. (You are proficient in ABC code right?)