AnsweredAssumed Answered

Method to obtain layout Part sizes for smart window resizing

Question asked by tcmeyers on May 4, 2016
Latest reply on May 5, 2016 by tcmeyers

I'd like to write a script to resize the height of a list window based on the number of records in the found set. In this application it will typically start with just one record, but as the user adds or deletes/omits records (by script) I want the window to get vertically longer/shorter so that it's always just the right size to show the header, body (X number of records worth) and footer without the user scrolling.


I haven't found a function to return the values of the Header height, Body height, and Footer height. I can manually provide these, but my script then needs to be manually updated any time the size of any of these change. I really want to avoid that. In fact I'd like the script to work in any similar situation, not just this one layout.


Am I missing the function? I didn't find it in Design functions, and unfortunately GetObjectAttributes won't work for me because I'm not allowed to assign object names to the Parts.


Ideas, please?