PowerBuilder 12.1, b7055
PowerBuilder 2019R3, b2703
Summary
I need a way to pass PowerBuilder data from one PB app to another, separate PB app.
Details
I discovered that our invoice production process was literally 5 times slower in PB2019R3 than in PB12.1. This is a show stopper, but I may have found a way to move forward.
I want to extract the invoice production process from the application and create a new and separate PBv12.1 application that does nothing but take data from the main app, do the processing, and return to the PB2019R3 main app.
To facilitate that, I need a BUNCH of data from the main app. How do we pass bunches of data around? With a structure, of course! I just started and this is what I need so far:
Sadly, the only link between the main app and the new exe is "commandline".
I can use FindWindowW (main_app) and get a handle to the main app, , but I don't know how to access internal data - strings, longs, DWs, and so on. I'm not sure if that's even possible.
For a DW I san SAVEAS an Excel file then import it into a copy of the dw in the new app, and I can do that for all of the required data in a similar manner, but....blech. I'[d rather be able to use dot notationi and reference the main_app internals.
Can this be done? If so, how?
Thank You!
Suggestion .... If you create an external DWO with the exact same columns as the Structure - then you can copy the values from the structure to the DWO in one command, for example:
DS/DC.object.data = <myStructure>
Then you can use the GetFullState() command for TCP/IP processing to get the DWO from AppA to AppB. AppB can then either deal with the DWO via a SetFullState() directly or after that populate the local structure from the DWO buffer, as follows:
<myStructure> = DS/DC.object.data
Tip: Use an array of the structure for passing multiple DWO rows.
Food for thought! ;-)
Regards ... Chris
http://chrispollach.blogspot.com/2015/05/wssg.html
The latest version of the structure generator is here: http://chrispollach.blogspot.com/2021/05/2021r2apps.html
(See item #3)