Sorting datagrid column with a tricj?

Bob Sneidar bobsneidar at iotecdigital.com
Mon Nov 5 12:12:15 EST 2018


I think at some point the way this needs to work is to send fillInData message to the script of the datagrid. Most LC devs see the datagrid as a complex magical black box kind of object, and are reticent to pull it apart or copy bits of it to other places to get it to do something different. 

If fillInData were sent to the datagrid after it was done doing it's thing, it would be much cleaner. I'm going to try to edit the default column behavior to do just that, and if I can get it to work, I'll submit a change request. 

Bob S


> On Nov 4, 2018, at 19:44 , Bob Sneidar via use-livecode <use-livecode at lists.runrev.com> wrote:
> 
> Thanks Trevor. I perused the lessons and the documentation but could not find anything that might aid me in this. I will have a look at that lesson! 
> 
> Bob S
> 
> 
>> On Nov 2, 2018, at 15:49 , Trevor DeVore via use-livecode <use-livecode at lists.runrev.com> wrote:
>> 
>> On Fri, Nov 2, 2018 at 5:16 PM Bob Sneidar via use-livecode <
>> use-livecode at lists.runrev.com> wrote:
>> 
>>> 
>>> What I would like to see added to the datagrid is a handler that
>>> intercepted the population of a field so what goes into the field can be
>>> custom formatted. This comes up a lot. Dates and numbers from an SQL query
>>> are unformatted, and having to go through the datagrid when populating and
>>> formatting each record's data before displaying it, and then reformatting
>>> it before pushing it back up to the database seems like more work than
>>> necessary.
>>> 
>> 
>> The Data Grid already supports this. Just customize the default column
>> behavior. Take a look at this article which truncates text that is too wide:
>> 
>> http://lessons.livecode.com/m/datagrid/l/7327-how-do-i-override-the-default-behavior-for-rendering-data-to-a-cell
>> 
>> -- 
>> Trevor DeVore
>> ScreenSteps
>> www.screensteps.com





More information about the use-livecode mailing list