Class oddity

Posted by James Palmer on 25-Jul-2014 08:43

Progress 11.2.1, on Windows. 

This is an odd one and I hope someone can help. I decided to try and write my first class, as a replacement for some legacy icode I needed to implement. I thought I'd give the class a go as it's much nicer than icode! 

I'll try and explain what's happening. 

I have a persistent procedure that I pass a temp table and a handle to a browse widget. It then populates the browse with the temp table contents. The idea being it's easier to maintain than using PDSOE to maintain freeform query browses. 

I've been trying to implement our way of allowing the user to customise the browse column sort order. We use the handle to a browse in an include to trawl through the columns and get the current order. I've moved that from icode to a class, so we pass the handle to the browse, and return the list of columns. This happens from the persistent procedure rather than the wcode as that is where the triggers reside. 

When I run the application in normal mode the return value is blank (the browse handle is valid). When I run in debug mode and step into the method in the class it returns non blank (as expected). 

Anyone got any ideas what I can look at to fix this?

All Replies

Posted by Tim Kuehn on 26-Jul-2014 09:18

I'd suggest a call to tech support - it sounds like a compiler or AVM issue.

Posted by James Palmer on 28-Jul-2014 05:08

Thanks Tim. Seems that there is a bug in my code somewhere as I've seen a pattern for when it works and doesn't work. Complicated though. So it's not a problem with the class per se.

Posted by James Palmer on 29-Jul-2014 06:16

Finally managed to track it down. There was an assign statement for various variables, one element of which failed when not in debug mode. I'm not sure why that's the case, but it was. As a result the other parts of the assign also didn't happen meaning a handle was never valid. Very confusing and convoluted!

This thread is closed