Intermittent DCBROWSE display problem

This forum is for eXpress++ general support.
Message
Author
reganc
Posts: 258
Joined: Thu Jan 28, 2010 3:08 am
Location: Hersham, Surrey, UK
Contact:

Intermittent DCBROWSE display problem

#1 Post by reganc »

This problem has been around in our system for years and I have mentioned it before but as more water has gone under the bridge since then I thought I'd try again in the hope that we might find a reason and fix for it.

Everything in an instance of our application running on a pc starts off normally as far as we can see. At some point, which appears to be random, the background colors of the browse object all of a sudden changes from the normal light background to a dark-gray.

I have attached a screenshot from one of our customers showing this just after it started occurring. Each one of our main dialogs is run in a different thread. On opening another dialog afterwards that also contains a browse object, the colours on that newly created browse are affected too.

Shutting the application and restarting it puts it back to normal.

This is not specific to one pc and I can find no common denominator (graphics processor, cpu, etc). Just for info, application uses Express++, List & Label, Xb2.net and ot4xb.

Has anyone seen this sort of thing before?
Attachments
Screenshot showing dodgy colours
Screenshot showing dodgy colours
dodgyscreen.png (96.88 KiB) Viewed 15647 times
Regan Cawkwell
Real Business Applications Ltd
http://www.rbauk.com

User avatar
sdenjupol148
Posts: 151
Joined: Thu Jan 28, 2010 10:27 am
Location: NYC

Re: Intermittent DCBROWSE display problem

#2 Post by sdenjupol148 »

Hi Regan,

I have had this problem as well.
It's not limited to one particular browse and there is no regular behavior to it.
I have noticed that it only happens when I'm scrolling fast with the mouse wheel.

I pointed it out to Roger well over a year ago but we couldn't figure out what was causing it.
Maybe we'll have better luck this time

Bobby

User avatar
Tom
Posts: 1173
Joined: Thu Jan 28, 2010 12:59 am
Location: Berlin, Germany

Re: Intermittent DCBROWSE display problem

#3 Post by Tom »

I've never seen anything like that, and I use tons of tons of browses in my app. It looks like you either changed something effecting your color codeblocks (parameters? functions? data used in there?) or the presentation parameters of the browse. Maybe there are some functions involved or vars (arrays) used as PRIVATEs or even PUBLICs. Tip: Look for the color value in your code and/or data. If the effect appears, look for the results of the color codeblocks. Then try to find lines of code where this values are used.
Best regards,
Tom

"Did I offend you?"
"No."
"Okay, give me a second chance."

User avatar
rdonnay
Site Admin
Posts: 4733
Joined: Wed Jan 27, 2010 6:58 pm
Location: Boise, Idaho USA
Contact:

Re: Intermittent DCBROWSE display problem

#4 Post by rdonnay »

Regan - Can you show me exactly what colors you are using in your browse?
When you say "normal light background", what does that mean?

Please show me the part of your code that sets the color for the background.
The eXpress train is coming - and it has more cars.

reganc
Posts: 258
Joined: Thu Jan 28, 2010 3:08 am
Location: Hersham, Surrey, UK
Contact:

Re: Intermittent DCBROWSE display problem

#5 Post by reganc »

rdonnay wrote:Regan - Can you show me exactly what colors you are using in your browse?
When you say "normal light background", what does that mean?

Please show me the part of your code that sets the color for the background.
Roger
If you look at the screen shot, the first cell in the browse directly below the product code field has the 'normal light background' color of GraMakeRGBColor( { 234 , 234 , 234 } ) which I return with a function called Off_White_Color().
That particular browse has 24 columns. 9 of those columns have a COLOR clause that calls the same function with a different element number.
The return variable is called aColor which by default returns {GRA_CLR_BLACK,GRA_CLR_BACKGROUND}.
There are loads of different tests in that codeblock setting lots of different color combinations. All except for 1 are standard GRA_CLR_* defines. The other 1 is the Off_White_Color (as above).
It may be useful for me to point out that the Vendor Code column does not have a COLOR clause at all (a few others shown also do not).
I can send the full code if you wish. But this problem does not only occur in this browse, it may happen at random to almost any browse in our application. But as mentioned it can always be cleared by exiting the application and restarting it.

Tom
Regarding your idea of finding where that color is used, believe me I have tried that. The color that it is being set is not one (as far as I can tell) that we set / use in our application. The headings in the top browse have a background of GRA_CLR_DARKGRAY and the only darker color we use is GRA_CLR_BLACK. This 'odd color' is darker than GRA_CLR_DARKGRAY.
Last edited by reganc on Mon Jun 05, 2017 9:11 am, edited 1 time in total.
Regan Cawkwell
Real Business Applications Ltd
http://www.rbauk.com

reganc
Posts: 258
Joined: Thu Jan 28, 2010 3:08 am
Location: Hersham, Surrey, UK
Contact:

Re: Intermittent DCBROWSE display problem

#6 Post by reganc »

SbDrakos wrote:Hi Regan,

I have had this problem as well.
It's not limited to one particular browse and there is no regular behavior to it.
I have noticed that it only happens when I'm scrolling fast with the mouse wheel.

I pointed it out to Roger well over a year ago but we couldn't figure out what was causing it.
Maybe we'll have better luck this time

Bobby
I feel better knowing it's not just my code that has the problem. Wait... I didn't give you any of my code, did I? :D
Regan Cawkwell
Real Business Applications Ltd
http://www.rbauk.com

reganc
Posts: 258
Joined: Thu Jan 28, 2010 3:08 am
Location: Hersham, Surrey, UK
Contact:

Re: Intermittent DCBROWSE display problem

#7 Post by reganc »

For info, the color that is being set is:

RGB 105,105,105 HSV 0,0,41 HTML: 696969
Regan Cawkwell
Real Business Applications Ltd
http://www.rbauk.com

User avatar
rdonnay
Site Admin
Posts: 4733
Joined: Wed Jan 27, 2010 6:58 pm
Location: Boise, Idaho USA
Contact:

Re: Intermittent DCBROWSE display problem

#8 Post by rdonnay »

The return variable is called aColor which by default returns {GRA_CLR_BLACK,GRA_CLR_BACKGROUND}.
I suspected something like this was going on.

GRA_CLR_BACKGROUND inherits the background of the parent.
If that background changes (for any reason), then the cell colors will change.

I recommend that you use GRA_CLR_PALEGRAY or any other color except GRA_CLR_BACKGROUND.
The eXpress train is coming - and it has more cars.

User avatar
sdenjupol148
Posts: 151
Joined: Thu Jan 28, 2010 10:27 am
Location: NYC

Re: Intermittent DCBROWSE display problem

#9 Post by sdenjupol148 »

Roger,

Whaaaaat!
And you couldn't tell me this a year ago? :-o

LOL

Bobby

reganc
Posts: 258
Joined: Thu Jan 28, 2010 3:08 am
Location: Hersham, Surrey, UK
Contact:

Re: Intermittent DCBROWSE display problem

#10 Post by reganc »

rdonnay wrote:
The return variable is called aColor which by default returns {GRA_CLR_BLACK,GRA_CLR_BACKGROUND}.
I suspected something like this was going on.

GRA_CLR_BACKGROUND inherits the background of the parent.
If that background changes (for any reason), then the cell colors will change.

I recommend that you use GRA_CLR_PALEGRAY or any other color except GRA_CLR_BACKGROUND.
Ok....

I will try to rethink the way that default color is being set. Is there a way to get the background colour of the parent as a value so it's sort of fixed in stone.

I still cannot understand is where that color change is actually coming from. But that may be impossible to fathom, I guess.

Thanks
Regan Cawkwell
Real Business Applications Ltd
http://www.rbauk.com

Post Reply