Skip to main content

Uniface 9: Columnwidth in tree widget.

  • November 19, 2018
  • 27 replies
  • 1 view

Show first post

27 replies

Jan Cees Boogaard

Columnwidth in tree widget.

Author: i.sharp@pcisystems.co.uk (Iain Sharp)

When the tree widget list view column sizes are altered, it now fires an extended trigger called columnwidth. When I define the column sizes, using $fieldproperties("FIELD")="FORMATS=CL10·!CL25·!TC6·!TL17·!CL·!CL6·!TL17·!CL13·!CL25·!CL·!CL25·!CL·; LABELS=Reference·!Location·!CHS·!Due Date·!Owner·!Priority·!Date Last Amended·!Contact·!Stock Item·!Cus. Order Ref.·!Developer·!Tester" I have been using character counts. If I resize the 4th column in the tree the columnwidth trigger gets ID=3 (because 1st column is Id 0), and width=117. Does anyone have a good tip as to what one could do WITH this information to make it useful for the next time around, I'd like to store the user's preferences for column sizes and reset the column widths to those the next time, but I don't know a sane way to translate 117 (or whatever) to TL17? What do you do about part characters? Or is there a method of telling the $fieldproperties to reset the columns in pixels? If not, what's the point of this trigger? Confused

 Jasper? Did you ever get anywhere with this, the same question just cropped up again here.    Regards,    Iain


Author: Iain Sharp (i.sharp@pcisystems.co.uk)

Jan Cees Boogaard

Columnwidth in tree widget.

Author: i.sharp@pcisystems.co.uk (Iain Sharp)

When the tree widget list view column sizes are altered, it now fires an extended trigger called columnwidth. When I define the column sizes, using $fieldproperties("FIELD")="FORMATS=CL10·!CL25·!TC6·!TL17·!CL·!CL6·!TL17·!CL13·!CL25·!CL·!CL25·!CL·; LABELS=Reference·!Location·!CHS·!Due Date·!Owner·!Priority·!Date Last Amended·!Contact·!Stock Item·!Cus. Order Ref.·!Developer·!Tester" I have been using character counts. If I resize the 4th column in the tree the columnwidth trigger gets ID=3 (because 1st column is Id 0), and width=117. Does anyone have a good tip as to what one could do WITH this information to make it useful for the next time around, I'd like to store the user's preferences for column sizes and reset the column widths to those the next time, but I don't know a sane way to translate 117 (or whatever) to TL17? What do you do about part characters? Or is there a method of telling the $fieldproperties to reset the columns in pixels? If not, what's the point of this trigger? Confused

Hi Theo, as you can see from my above formula, it is possible to calculate the overhad and add that to the equation even using just normal uniface code.


Author: ulrich-merkel (ulrichmerkel@web.de)