From: Kevin on 2 Jun 2010 06:33 Stephen, Okay thanks. I had assumed that the conditions were added to a list and each run rather than it stopping at the first condition that returns true. Thanks again. Kevin "Stephen Quinn" <stevejqNO(a)bigpondSPAM.net.au> wrote in message news:VQpNn.612$Ls1.301(a)news-server.bigpond.net.au: > Kevin > > > If you look at my original post you will see that the third condition is > > on a different column, and it does not work. Changing the third condition > > to first, it works and the other two don't. From what you are saying it > > should work but doesn't. > Nope - your ADDing it to the BROWSER > - oBrw:ColorCondition:Add( oColorCond ) > > When adding conditions to the browser they are evaulated in the order added, > when one evaluates to TRUE the evaulation sequence is ended. > > I can see what the problem is now with the extra info you provided. > What I showed was the foreground/background colour change for the ROW (4 > conditions) > > If you want to affect the forground of a single column then you apply the > condition to the COLUMN not the BROWSER. > Eg > oCol := oBrw:GetOpenColumn( #LITRES ) > > oColorCond := bColorCondition{"Server:Litres > 0.00", self:Server, > Color{COLORBLUE}} > > oCol:ColorCondition:Add( oColorCond ) > > CYA > Steve
From: Stephen Quinn on 2 Jun 2010 06:49 Kevin > I had assumed that the conditions were added to a list They are - an internal array - if you have the bBrowser source take a look (IIRC ConditionList), it's also in the help file. > and each run rather than it stopping at the first condition that returns > true. Conditions added to the browser affect the whole browser (ie every column in the row) If you want to change things for columns you need to add them to the columns, if you want to affect 2 columns with the same condition you need to add that condition to both columns. CYA Steve
From: Geoff Schaller on 2 Jun 2010 07:23 Kevin, No - that wouldn't make sense because you would never be able to predict the outcome. You'd be stuck working out some complex hierarchy to apply. But also, it is very clearly documented in the Help file. The Help is worth reading through cover to cover, at least 3 times. I still pick up new stuff... (as well as scouring the source code for ideas and clues). Columns override browser override defaults. But the column always wins. Cheers, Geoff "Kevin" <kdmurphy(a)eircom.net> wrote in message news:WrqNn.114$K4.125(a)news.indigo.ie: > Stephen, > > Okay thanks. > > I had assumed that the conditions were added to a list and each run > rather than it stopping at the first condition that returns true. > > Thanks again. > > Kevin > > "Stephen Quinn" <stevejqNO(a)bigpondSPAM.net.au> wrote in message > news:VQpNn.612$Ls1.301(a)news-server.bigpond.net.au: > > > > Kevin > > > > > > If you look at my original post you will see that the third condition is > > > on a different column, and it does not work. Changing the third condition > > > to first, it works and the other two don't. From what you are saying it > > > should work but doesn't. > > > Nope - your ADDing it to the BROWSER > > - oBrw:ColorCondition:Add( oColorCond ) > > > > When adding conditions to the browser they are evaulated in the order added, > > when one evaluates to TRUE the evaulation sequence is ended. > > > > I can see what the problem is now with the extra info you provided. > > What I showed was the foreground/background colour change for the ROW (4 > > conditions) > > > > If you want to affect the forground of a single column then you apply the > > condition to the COLUMN not the BROWSER. > > Eg > > oCol := oBrw:GetOpenColumn( #LITRES ) > > > > oColorCond := bColorCondition{"Server:Litres > 0.00", self:Server, > > Color{COLORBLUE}} > > > > oCol:ColorCondition:Add( oColorCond ) > > > > CYA > > Steve
From: Kevin on 2 Jun 2010 08:29 Geoff, I never really had to think about it as I did not have many colour conditions and this never happened before. The way it works now makes sense following Stephen's and your replies. Where in the help file does it state the way the conditions work? I can see that the conditions are added to a list but I cannot see where it explains how that list is processed and that when one condition returns true, the remaining items in the list are not processed. If that is there I have managed to miss it. Kevin "Geoff Schaller" <geoffx(a)softxwareobjectives.com.au> wrote in message news:tarNn.637$Ls1.279(a)news-server.bigpond.net.au: > Kevin, > > No - that wouldn't make sense because you would never be able to predict > the outcome. You'd be stuck working out some complex hierarchy to apply. > But also, it is very clearly documented in the Help file. The Help is > worth reading through cover to cover, at least 3 times. I still pick up > new stuff... (as well as scouring the source code for ideas and clues). > > Columns override browser override defaults. > But the column always wins. > > Cheers, > > Geoff > > > > "Kevin" <kdmurphy(a)eircom.net> wrote in message > news:WrqNn.114$K4.125(a)news.indigo.ie: > > > Stephen, > > > > Okay thanks. > > > > I had assumed that the conditions were added to a list and each run > > rather than it stopping at the first condition that returns true. > > > > Thanks again. > > > > Kevin > > > > "Stephen Quinn" <stevejqNO(a)bigpondSPAM.net.au> wrote in message > > news:VQpNn.612$Ls1.301(a)news-server.bigpond.net.au: > > > > > > > Kevin > > > > > > > > > If you look at my original post you will see that the third condition is > > > > on a different column, and it does not work. Changing the third condition > > > > to first, it works and the other two don't. From what you are saying it > > > > should work but doesn't. > > > > > Nope - your ADDing it to the BROWSER > > > - oBrw:ColorCondition:Add( oColorCond ) > > > > > > When adding conditions to the browser they are evaulated in the order added, > > > when one evaluates to TRUE the evaulation sequence is ended. > > > > > > I can see what the problem is now with the extra info you provided. > > > What I showed was the foreground/background colour change for the ROW (4 > > > conditions) > > > > > > If you want to affect the forground of a single column then you apply the > > > condition to the COLUMN not the BROWSER. > > > Eg > > > oCol := oBrw:GetOpenColumn( #LITRES ) > > > > > > oColorCond := bColorCondition{"Server:Litres > 0.00", self:Server, > > > Color{COLORBLUE}} > > > > > > oCol:ColorCondition:Add( oColorCond ) > > > > > > CYA > > > Steve
From: Geoff Schaller on 2 Jun 2010 09:05 Kevin, Read the pages on bBrowser:ColorCondition, bDataColumn:ColorCondition and the various links that follow on from these pages. But when you read the bColorCondition:Eval() the Init methods and the samples. I guess it isn't in one place but I always read the source code where there are even more comments. Geoff "Kevin" <kdmurphy(a)eircom.net> wrote in message news:F8sNn.116$K4.115(a)news.indigo.ie: > Geoff, > > I never really had to think about it as I did not have many colour > conditions and this never happened before. The way it works now makes > sense following Stephen's and your replies. > > Where in the help file does it state the way the conditions work? I can > see that the conditions are added to a list but I cannot see where it > explains how that list is processed and that when one condition returns > true, the remaining items in the list are not processed. If that is > there I have managed to miss it. > > Kevin > > > "Geoff Schaller" <geoffx(a)softxwareobjectives.com.au> wrote in message > news:tarNn.637$Ls1.279(a)news-server.bigpond.net.au: > > > > Kevin, > > > > No - that wouldn't make sense because you would never be able to predict > > the outcome. You'd be stuck working out some complex hierarchy to apply. > > But also, it is very clearly documented in the Help file. The Help is > > worth reading through cover to cover, at least 3 times. I still pick up > > new stuff... (as well as scouring the source code for ideas and clues). > > > > Columns override browser override defaults. > > But the column always wins. > > > > Cheers, > > > > Geoff > > > > > > > > "Kevin" <kdmurphy(a)eircom.net> wrote in message > > news:WrqNn.114$K4.125(a)news.indigo.ie: > > > > > > Stephen, > > > > > > Okay thanks. > > > > > > I had assumed that the conditions were added to a list and each run > > > rather than it stopping at the first condition that returns true. > > > > > > Thanks again. > > > > > > Kevin > > > > > > "Stephen Quinn" <stevejqNO(a)bigpondSPAM.net.au> wrote in message > > > news:VQpNn.612$Ls1.301(a)news-server.bigpond.net.au: > > > > > > > > > > > Kevin > > > > > > > > > > > > > If you look at my original post you will see that the third condition is > > > > > on a different column, and it does not work. Changing the third condition > > > > > to first, it works and the other two don't. From what you are saying it > > > > > should work but doesn't. > > > > > > > > Nope - your ADDing it to the BROWSER > > > > - oBrw:ColorCondition:Add( oColorCond ) > > > > > > > > When adding conditions to the browser they are evaulated in the order added, > > > > when one evaluates to TRUE the evaulation sequence is ended. > > > > > > > > I can see what the problem is now with the extra info you provided. > > > > What I showed was the foreground/background colour change for the ROW (4 > > > > conditions) > > > > > > > > If you want to affect the forground of a single column then you apply the > > > > condition to the COLUMN not the BROWSER. > > > > Eg > > > > oCol := oBrw:GetOpenColumn( #LITRES ) > > > > > > > > oColorCond := bColorCondition{"Server:Litres > 0.00", self:Server, > > > > Color{COLORBLUE}} > > > > > > > > oCol:ColorCondition:Add( oColorCond ) > > > > > > > > CYA > > > > Steve
First
|
Prev
|
Next
|
Last
Pages: 1 2 3 Prev: How to disable messagebeep (sound) when click listviewitem bymouse ? Next: ADS and ReportPro 2 |