Re: [U2] What Program Am I?
> From: HENDERSON MIKE > >From (IIRC) 10.0 onwards, there's the "SYSTEM(9001)" pseudo-variable > >which contains the UV CALL Stack. > It's formatted a bit funny, but there may be a routine on the Pickwiki > to make it a sensible format. That reminds me: PickWiki also mentions the UD program CALL.STACK and a UV program called LAYER.STACK. An old U2 forum post suggests using a command like: PORT.STATUS PID 9 CALL.STACK which for UV might be PORT.STATUS PID 9 LAYER.STACK ? Refs: http://www.mail-archive.com/u2-users%40listserver.u2ug.org/msg173 14.html http://www.pickwiki.com/cgi-bin/wiki.pl?ViewCallStack Does any of that apply to the OP request? Tony Gravagno Nebula Research and Development TG@ remove.pleaseNebula-RnD.com ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
Re: [U2] What Program Am I?
Agreed about use of SYSTEM(9001), however as it is not clear on the platform there is one caveat if you are using UniObjects. You may need to ensure that you are using at least UV 10.2.4 as some previous versions did a hang on consecutive calls to this function (Issue 8283). Am not sure when this bug was introduced so you may be ok. "phil walker" wrote in message news:<6806801183013245804b6a7c6b34750715a...@hera.gnosys.local>... > Depending on the version of UV you are on you should be able to access > SYSTEM(9001) from memory. This is an array which contains the call > stack. > > > -Original Message- > > From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users- > > boun...@listserver.u2ug.org] On Behalf Of David A Barrett > > Sent: Wednesday, 24 June 2009 8:46 a.m. > > To: u2-users@listserver.u2ug.org > > Subject: [U2] What Program Am I? > > > > We've got a UV client/server application with a thick VB client. The > > vintage is around 1997, and the architecture has a debug mode that I > > leave ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
Re: [U2] What Program Am I?
Regarding debugging phantoms, we've developed an intercept mechanism so when a phantom is triggered from the VB GUI we capture the parameters and return to VB with an error. Then, the programmer can restart the phantom code - but running under a normal session - using an entry point routine that picks up the parameters and launches into the appropriate code. This is great for debugging, and also flagging up non-numerics and unassigned variables - these seem to get missed when the code is only ever run as a phantom. Ed -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of David A Barrett Sent: 23 June 2009 21:33 To: u2-users@listserver.u2ug.org Subject: [U2] What Program Am I? We've got a UV client/server application with a thick VB client. The vintage is around 1997, and the architecture has a debug mode that I leave on all the time that logs the calls back to the server and the arguments passed back and forth. The server side stuff is all phantomed off, so the output is in the &PH& file. Additionally, you can put display statements in the server side programs and the output from these will be sent to the &PH& record, mingled in with the other stuff. Debugging is old school, as you can't step through programs and any DEBUG statement will halt the server side program with no ability to do interactive I/O, and the client side window will appear hung, requiring the three finger salute. So you spend a lot of time putting in lines of code that look like: DISPLAY "HERE I AM #17" and the like. Eventually I got fed up with counting value marks in &PH& file records and wrote a routine that formats MV data up nicely for display and makes a lot of tedious stuff easier. It makes my life easier. For tricky parts of the system, I often leave the debugging output calls in the programs; in case I need to come back some day and fiddle some more. But there is one thing I'd like to be able to do... It would be super if it were possible to see the call stack from a running program. Kind of like the the UV "T" debugger command. Sometimes I'm just wondering, "How the hell did I get *there*". Or I'll see debugging output in the &PH& file and I wonder, "What program is that from?". In those cases it would be useful to have the call stack sitting beside the output in the &PH& file. Does anybody know a way to do this? I've even considered building a little $INCLUDE snippet that updates @USER1 or a named common area and recompiling ever server side program with it added. Any help will be greatly appreciated. Dave Barrett, Lawyers' Professional Indemnity Company ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users --- Please remember to recycle wherever possible. Reduce, reuse, recycle, think do you need to print this e-mail? --- This e-mail and any attachment(s), is confidential and may be legally privileged. It is intended solely for the addressee. If you are not the addressee, dissemination, copying or use of this e-mail or any of its content is prohibited and may be unlawful. If you are not the intended recipient please inform the sender immediately and destroy the e-mail, any attachment(s) and any copies. All liability for viruses is excluded to the fullest extent permitted by law. It is your responsibility to scan or otherwise check this email and any attachment(s). Unless otherwise stated (i) views expressed in this message are those of the individual sender (ii) no contract may be construed by this e-mail. Emails may be monitored and you are taken to consent to this monitoring. Civica Services Limited, Company No. 02374268; Civica UK Limited, Company No. 01628868 Both companies are registered in England and Wales and each has its registered office at 2 Burston Road, Putney, London, SW15 6AR. --- ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
Re: [U2] What Program Am I?
Depending on the version of UV you are on you should be able to access SYSTEM(9001) from memory. This is an array which contains the call stack. > -Original Message- > From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users- > boun...@listserver.u2ug.org] On Behalf Of David A Barrett > Sent: Wednesday, 24 June 2009 8:46 a.m. > To: u2-users@listserver.u2ug.org > Subject: [U2] What Program Am I? > > We've got a UV client/server application with a thick VB client. The > vintage is around 1997, and the architecture has a debug mode that I > leave > on all the time that logs the calls back to the server and the > arguments > passed back and forth. The server side stuff is all phantomed off, so > the > output is in the &PH& file. Additionally, you can put display > statements > in the server side programs and the output from these will be sent to > the > &PH& record, mingled in with the other stuff. > > Debugging is old school, as you can't step through programs and any > DEBUG > statement will halt the server side program with no ability to do > interactive I/O, and the client side window will appear hung, requiring > the three finger salute. So you spend a lot of time putting in lines > of > code that look like: > > DISPLAY "HERE I AM #17" > > and the like. Eventually I got fed up with counting value marks in > &PH& > file records and wrote a routine that formats MV data up nicely for > display and makes a lot of tedious stuff easier. It makes my life > easier. > For tricky parts of the system, I often leave the debugging output > calls > in the programs; in case I need to come back some day and fiddle some > more. > > But there is one thing I'd like to be able to do... > > It would be super if it were possible to see the call stack from a > running > program. Kind of like the the UV "T" debugger command. Sometimes I'm > just wondering, "How the hell did I get *there*". Or I'll see > debugging > output in the &PH& file and I wonder, "What program is that from?". In > those cases it would be useful to have the call stack sitting beside > the > output in the &PH& file. > > Does anybody know a way to do this? I've even considered building a > little $INCLUDE snippet that updates @USER1 or a named common area and > recompiling ever server side program with it added. > > Any help will be greatly appreciated. > > Dave Barrett, > Lawyers' Professional Indemnity Company > ___ > U2-Users mailing list > U2-Users@listserver.u2ug.org > http://listserver.u2ug.org/mailman/listinfo/u2-users > ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
Re: [U2] What Program Am I? {Unclassified}
Dave, >From (IIRC) 10.0 onwards, there's the "SYSTEM(9001)" pseudo-variable which contains the UV CALL Stack. It's formatted a bit funny, but there may be a routine on the Pickwiki to make it a sensible format. HTH Regards Mike -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of David A Barrett Sent: Wednesday, 24 June 2009 8:33 a.m. To: u2-users@listserver.u2ug.org Subject: [U2] What Program Am I? [Snip] It would be super if it were possible to see the call stack from a running program. Kind of like the the UV "T" debugger command. Sometimes I'm just wondering, "How the hell did I get *there*". Or I'll see debugging output in the &PH& file and I wonder, "What program is that from?". In those cases it would be useful to have the call stack sitting beside the output in the &PH& file. Does anybody know a way to do this? I've even considered building a little $INCLUDE snippet that updates @USER1 or a named common area and recompiling ever server side program with it added. Any help will be greatly appreciated. Dave Barrett, Lawyers' Professional Indemnity Company The information contained in this Internet Email message is intended for the addressee only and may contain privileged information, but not necessarily the official views or opinions of the New Zealand Defence Force. If you are not the intended recipient you must not use, disclose, copy or distribute this message or the information in it. If you have received this message in error, please Email or telephone the sender immediately. ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
[U2] What Program Am I?
We've got a UV client/server application with a thick VB client. The vintage is around 1997, and the architecture has a debug mode that I leave on all the time that logs the calls back to the server and the arguments passed back and forth. The server side stuff is all phantomed off, so the output is in the &PH& file. Additionally, you can put display statements in the server side programs and the output from these will be sent to the &PH& record, mingled in with the other stuff. Debugging is old school, as you can't step through programs and any DEBUG statement will halt the server side program with no ability to do interactive I/O, and the client side window will appear hung, requiring the three finger salute. So you spend a lot of time putting in lines of code that look like: DISPLAY "HERE I AM #17" and the like. Eventually I got fed up with counting value marks in &PH& file records and wrote a routine that formats MV data up nicely for display and makes a lot of tedious stuff easier. It makes my life easier. For tricky parts of the system, I often leave the debugging output calls in the programs; in case I need to come back some day and fiddle some more. But there is one thing I'd like to be able to do... It would be super if it were possible to see the call stack from a running program. Kind of like the the UV "T" debugger command. Sometimes I'm just wondering, "How the hell did I get *there*". Or I'll see debugging output in the &PH& file and I wonder, "What program is that from?". In those cases it would be useful to have the call stack sitting beside the output in the &PH& file. Does anybody know a way to do this? I've even considered building a little $INCLUDE snippet that updates @USER1 or a named common area and recompiling ever server side program with it added. Any help will be greatly appreciated. Dave Barrett, Lawyers' Professional Indemnity Company ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users