Is there a way to do profile tracing (not pbdebug) with the PB executable?
Is there a way to do profile tracing (not pbdebug) with the PB executable?
Thanks John - I am looking at that now. One additional question - after a profile trace file (.pbp) has been created, I know how to view the contents in PowerBuilder - is there a way that file can be viewed by using PB code in my application?
I found this documentation via a web search for the terms "w_starttrace powerbuilder profiling":
https://docs.appeon.com/pb2019/pbug/ch32s02.html
A little ways down (just past the "Using a Window" sub-heading), is a mention of some sample code. Since I have not watched the Elevate 2021 session in question, I don't know if this is the same window you are looking for... However, the URL in the aforementioned documentation now only takes you to the PowerBuilder section of CodeXchange.
Fortunately, doing a search for "PB Code Profiling" from that web page in CodeXchange found this:
I hope this is what you are looking for.
Best regards, John
Thanks - I saw that but was hoping that John Strano's sample profile trace window code was available somewhere. If not it mentions that the window w_starttrace is available from an old sybase link which is no longer there. Is that somewhere that can be downloaded and ready to roll?
Does anyone know if the profiler trace window/code (done by John Strano provided at Elevate 2021: https://www.youtube.com/watch?) is available to use and if so where?
I have an example of how to activate /PBDEBUG in your code so you can have it active only where needed.
https://www.topwizprogramming.com/freecode_pbdebug.html
Make sure to change the dll name in the external function declarations. It uses undocumented PBVM functions.
Thanks for the replies. Is there a way to do profile tracing without adding code to an existing exe similar to pbdebug? I was hoping there was some kind of parameter similar starting your app from the command line like: application.exe /pbdebug
Hi Paul;
Mark's links should provide you with a good overview of how to create a Profiling Feature for any PB App!
FYI: My STD framework has that all built-in and it can also show you how your app looks like from the MS-Windows Monitoring, Display O/S / App memory conditions, alert you GDI issues, build a Process Model, etc all in real time and right within your PB App!
Example1:
Example2:
FYI: http://chrispollach.blogspot.com/2023/03/framework.html
The framework is free & open source to use but also, feel free to help yourself to any interesting code that you might find. ;-)
Note: the framework also includes the ability to Start or Stop the PBDEBUG tracing in the VM under program control! <=
Regards ... Chris
Hi Paul,
Have a look at these 2 links for more info on tracing as the /pbdebug option, as explained, is just one approach:
https://docs.appeon.com/pb2019/pbug/ch33s08.html
https://docs.appeon.com/pb2019/pbug/ch32s05.html
As well, John Strano provided an excellent session at Elevate 2021 on this very subject: https://www.youtube.com/watch?v=LwqytkvDkUg
HTH...regards,
Mark
Hi, Paul -
This may help:
https://docs.appeon.com/pb2021/pbug/Tracing_and_Profiling_Applications.html#ug94233
Best regards, John