They're USUALLY displayed correctly (not ALWAYS) and it's driving me insane lol.....
I've tried everything I can think of and struggled with this problem (on the side-burner) since last winter.....
All tables are indexed properly etc. (dbf's) ~ This occurs occasionally with a seemingly "unanticipated yet predictable frequency."
(Open the form and access the same record data twice... One time it happens, and the next time it doesn't.)
The objects which SOMETIMES don't always display 100% correctly (with the proper attributes, color etc.) are dynamically based on "calculated summary fields".
Ironically, ALL the data in ALL the fields both on the form and in the browses (based on these SAME calculated summary fields) is ALWAYS "to the penny" correct....
These "attribute miss-draws" are almost random.....
Some of the objects attributes (on this same form) occasionally without any recognizable pattern fail to display properly (color/font attributes etc.) And if/when they don't display properly: All I have to do is move up/down in the browse and it's fixed. (It doesn't appear to be related to a "first/last object in browse with initial focus" issue either. ~ I'm familiar with that "anomaly.")
Regardless: Whether these objects show or don't show the dynamic attributes properly: Every bit of data (field and browse cells) on this form are correctly calculated and displayed! (Again, based on the exact same calculated field data.) ~ So what is going on?
FWIW: The form updates all the data and the display quickly. ("Lightening fast" if I had to describe it!) ~ Especially given there are at present ~2000 child/indexed records from which these calculated fields are generated) So with the exception of this anomaly, the form appears to be working efficiently....
I've gone as far as to write a function that reassigns the correct attributes using the same calculated fields data (attached it to a button "onPush" event) which confirms both the data and logic is good.
I've attached this function to every event imaginable but it's like putting the cart in front of the horse I think. The only way I have achieve correct screen painting s to add WAIT_UNTIL(.T.=.F.,1,1), and I've also tried several other XB "wait function" variations to no avail. (Using the "WAIT_UNTIL" solution, I fear that as the data set grows, the wait must grow also or fail. ~ One thought I had was some other wait condition other than waiting a fixed period of time, or until .T. = .F. lol.....)
I've also tried all the other XBASIC_WAIT_UNTIL() type functions. I can find... I've looked for object properties/methods etc, but found nothing. (Even browse through all the a5_ and a5. methods etc.) Ironically, I do know that if this was field data, it would be relatively easy to correct with a refresh command. (Which reminds me of one other significant consideration): With the IW session properly set, it's impossible to correctly refresh/repaint the display attributes using any "refresh/repaint type" xBasic commands I'm aware of. (unlike field data/RTF fields which are/is easy to correct) So it appears as if the object attributes (unlike the field values) are not always getting/seeing the correct/finalized calculated field data. From the IW, the only way to correct the display data is to call the function I wrote which sets each field attribute individually.
At present (not liking the "WAIT_UNTIL(.T.=F.1,1) which requires a "fixed one second period of waiting" (which may fail with growing data sets) I've resorted to calling the function on an "onTimer" event set to trigger every 2 seconds. (FWIW: At present with 2,000 detail records the WAIT_UNTIL solution seems to work.)
Because of the actual data displaying correctly, this doesn't appear to be a table size .dbf issue....
I've been dealing with this oddity for months. None of the normal stuff seems to address this problem.....
Is there some way to force Alpha to "flag" these dynamic attribute fields as "dirty" before calling a repaint/refresh/redraw function etc? ~ If so, I can't find it.
PS:
After asking for help here/writing this..... I'm wondering whether some type of form based fetch commands (on the underlying child table) could possibly address this too? Spent countless hours (on the side) trying everything else I could think of.
I've tried everything I can think of and struggled with this problem (on the side-burner) since last winter.....
All tables are indexed properly etc. (dbf's) ~ This occurs occasionally with a seemingly "unanticipated yet predictable frequency."
(Open the form and access the same record data twice... One time it happens, and the next time it doesn't.)
The objects which SOMETIMES don't always display 100% correctly (with the proper attributes, color etc.) are dynamically based on "calculated summary fields".
Ironically, ALL the data in ALL the fields both on the form and in the browses (based on these SAME calculated summary fields) is ALWAYS "to the penny" correct....
These "attribute miss-draws" are almost random.....
Some of the objects attributes (on this same form) occasionally without any recognizable pattern fail to display properly (color/font attributes etc.) And if/when they don't display properly: All I have to do is move up/down in the browse and it's fixed. (It doesn't appear to be related to a "first/last object in browse with initial focus" issue either. ~ I'm familiar with that "anomaly.")
Regardless: Whether these objects show or don't show the dynamic attributes properly: Every bit of data (field and browse cells) on this form are correctly calculated and displayed! (Again, based on the exact same calculated field data.) ~ So what is going on?
FWIW: The form updates all the data and the display quickly. ("Lightening fast" if I had to describe it!) ~ Especially given there are at present ~2000 child/indexed records from which these calculated fields are generated) So with the exception of this anomaly, the form appears to be working efficiently....
I've gone as far as to write a function that reassigns the correct attributes using the same calculated fields data (attached it to a button "onPush" event) which confirms both the data and logic is good.
I've attached this function to every event imaginable but it's like putting the cart in front of the horse I think. The only way I have achieve correct screen painting s to add WAIT_UNTIL(.T.=.F.,1,1), and I've also tried several other XB "wait function" variations to no avail. (Using the "WAIT_UNTIL" solution, I fear that as the data set grows, the wait must grow also or fail. ~ One thought I had was some other wait condition other than waiting a fixed period of time, or until .T. = .F. lol.....)
I've also tried all the other XBASIC_WAIT_UNTIL() type functions. I can find... I've looked for object properties/methods etc, but found nothing. (Even browse through all the a5_ and a5. methods etc.) Ironically, I do know that if this was field data, it would be relatively easy to correct with a refresh command. (Which reminds me of one other significant consideration): With the IW session properly set, it's impossible to correctly refresh/repaint the display attributes using any "refresh/repaint type" xBasic commands I'm aware of. (unlike field data/RTF fields which are/is easy to correct) So it appears as if the object attributes (unlike the field values) are not always getting/seeing the correct/finalized calculated field data. From the IW, the only way to correct the display data is to call the function I wrote which sets each field attribute individually.
At present (not liking the "WAIT_UNTIL(.T.=F.1,1) which requires a "fixed one second period of waiting" (which may fail with growing data sets) I've resorted to calling the function on an "onTimer" event set to trigger every 2 seconds. (FWIW: At present with 2,000 detail records the WAIT_UNTIL solution seems to work.)
Because of the actual data displaying correctly, this doesn't appear to be a table size .dbf issue....
I've been dealing with this oddity for months. None of the normal stuff seems to address this problem.....
Is there some way to force Alpha to "flag" these dynamic attribute fields as "dirty" before calling a repaint/refresh/redraw function etc? ~ If so, I can't find it.
PS:
After asking for help here/writing this..... I'm wondering whether some type of form based fetch commands (on the underlying child table) could possibly address this too? Spent countless hours (on the side) trying everything else I could think of.
Comment