PxPlus User Forum

Twitter Twitter Twitter

Author Topic: Custom Resize Logic  (Read 1127 times)

bbssupport

  • Silver Member
  • ***
  • Posts: 34
    • View Profile
Custom Resize Logic
« on: November 29, 2020, 05:12:48 PM »
Hi All,

I'm wondering if there is a way that I cannot see in the documentation to initiate a custom resize program post-resize on nomads panels.

I found that I could use the alternate panel feature to execute pre-resize code, but cannot find a programming hook to run post-resize code.

An example of where this is useful is after a resize I could check if the panel is wider than the list box columns and set the AutoColSize=1 to get the columns to expand out.... or code in which columns we want to expand and which we don't.

Ideally a new feature to be able to lock some column sizes in a list box when AutoColSize=1 so only some columns grow...and another feature to say columns only grow and cannot shrink would be amazing! However i'm happy to handle this myself in code if I can find the correct hook to latch the code onto.

Thanks in advance!
Chris

Jane Raymond

  • Staff
  • Diamond Member
  • *****
  • Posts: 280
    • View Profile
    • PVX Plus Technologies
Re: Custom Resize Logic
« Reply #1 on: November 30, 2020, 09:08:31 AM »
I don't know if this will accomplish what you want, but try setting a User Defined CTL Value of -1105 for your panel.
Jane Raymond
Software Developer
PVX Plus Technologies Ltd.

bbssupport

  • Silver Member
  • ***
  • Posts: 34
    • View Profile
Re: Custom Resize Logic
« Reply #2 on: December 01, 2020, 03:58:53 PM »
Hi Jane,

Thank you for your reply. That works perfectly except for when panel persistance is used, the CTL doesn't fire when panels are first open and automatically resized.

I've resorted to adding some code to the *winproc.rsz program in the DONE_RESIZING subroutine to capture all resizes, instead of using the CTL value

Thanks for your help.

Chris