Complex Grid Field Styles or Exceptions

Michael Monschau michael at brainydata.co.uk
Mon Sep 11 12:31:13 EDT 2017


Hi Gav,

I demonstrate how to do this in my Notation session at EurOmnis, using a single line of code to change the foreground colour of a background text object in the grid.

I am debating whether I should tell you now or make you come to my session :)

Here is the line strait from my session

Do iList.$sendall(iGridRef.$objs.Text.[iList.$line].$forecolor.$assign(pick(iList.Value,rgb(x,x,x),rgb(y,y,y),etc)))

the bit [iList.$line] is the grid exception bit so each line gets the exception based on a value in the list

Hope this helps

Michael



> On 6 Sep 2017, at 15:32, Gavin Foster <omnislist at dataweaver.com> wrote:
> 
> Hi $all,
> 
> Using Studio 6.03:
> 
> In a headed list, a column can have a style() function that changes the colour of the text dependant on some field value.
> This happens at redraw.
> 
> In a complex grid, we have $exceptions which allow us to change the colour of an individual cell under program control. e.g.
> Do lvGridRef.$objs.<MyFieldName>.<MyLineNumber>.$textcolor.$assign(kRed)
> 
> This is a pain to perform for each line in the list, each time the complex grid is redrawn.
> Is there some way of doing this/applying a style() to a field in a complex grid?
> 
> Rgds,
> Gav
> _____________________________________________________________
> Manage your list subscriptions at http://lists.omnis-dev.com




More information about the omnisdev-en mailing list