Re: setting row and cell color in entity selection listboxes

2021-08-10 Thread Keisuke Miyako via 4D_Tech
for clarification: the reason for using the Form object, as in Form.meta, is to be memory efficient. if you only have 3 possible paint patterns, it would be more efficient to create the objects in advance: e.g. $meta:=New collection(New object;New object;New object;New object;New object;New

Re: setting row and cell color in entity selection listboxes

2021-08-10 Thread Michael Ferguson via 4D_Tech
Thanks, Miyako, So, this works: //form method Case of :(Form event=On Load ) Form .meta:=New object End case //Color

Re: setting row and cell color in entity selection listboxes

2021-08-10 Thread Keisuke Miyako via 4D_Tech
I activated on display detail. activating On Display Detail is optional. it is not required for Meta Exp. to work. but your Color method is wrong. you basically need as many meta objects as the number of different colour combinations to display at the same time. in your code you have just

Re: setting row and cell color in entity selection listboxes

2021-08-06 Thread Keisuke Miyako via 4D_Tech
the meta expression is evaluated during the On Display Detail event. that would be all the rows visible on screen, plus a cache of rows prefetched for vertical scroll. typically that would be the same number as the rows visible on screen. how to bind: you create a project method, then enter

Re: setting row and cell color in entity selection listboxes

2021-08-06 Thread nug via 4D_Tech
Michael, For row colors (background and separate for fonts) there is a property of the listbox which will accept either a formula or method call (better) which will need to return an RGB color. I do not know, but would expect that there is a cell color property too. > On Aug 6, 2021, at 10:28

Re: setting row and cell color in entity selection listboxes

2021-08-06 Thread Michael Ferguson via 4D_Tech
Thank you Miyako. That was helpful. However the documentation does not illustrate the context in which the row coloring method is called. Would the method be added to the column expression? Otherwise, I don’t see a way to “bind” it to the listbox or a listbox column. Would this normally be

Re: setting row and cell color in entity selection listboxes

2021-08-05 Thread Keisuke Miyako via 4D_Tech
if you are looking for practical examples: https://blog.4d.com/display-a-collection-in-a-listbox/ every essential feature since v16 has a featured blog post, often with a video and/or sample code. ** 4D Internet Users Group (4D

Re: setting row and cell color in entity selection listboxes

2021-08-05 Thread Dani Beaubien via 4D_Tech
This page of the documentation gives the mechanism to use to do what you are wanting. https://developer.4d.com/docs/en/FormObjects/propertiesText.html#meta-info-expression Dani Beaubien Open Road

setting row and cell color in entity selection listboxes

2021-08-05 Thread Michael Ferguson via 4D_Tech
Hi, I can’t find anything on this in the documentation. Can someone show me how to do this? Thanks, Michael Ferguson ** 4D Internet Users Group (4D iNUG) New Forum: https://discuss.4D.com Archive: