Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Grid HighLighter very slow changing row
Message
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
00467275
Message ID:
00467450
Views:
13
>>I have this problem from the first version of this grid class.
>>I think this is a good class for the grid but I can't use it because it's very very slow.
>>I have VFP6 SP4 with a PIII500 with 128Kb.
>
>Hola, Esteban.
>
>Have you tried the latest? It's 3.6 and you can find it easily in the Files Section looking for it with the cool new All Files list.
>
>The speed is not as if it was implemented natively, but if you need its features, in my opinion, is just a worth price to pay.
>
>Hope this helps.


There are two parts in it. Essentially on INIT() Grid Highlighter sets the grid native Dynamic... properties for its work. That is not slower than any other way to set and use Dynamic... properties.

Then, the code in .Highlight_row() method operates with extra features - current cell and header highlighting where the code have to take care of what is currently selected, considering that:

Columns may be moved around the grid so the ActiveColumn is not the same as ColumnOrder.

It has to know what kind of control is the CurrentControl (Textbox, Combobox, Picture, etc. and whether it has .Backcolor property.

It takes care of setting the colors for the active column Header and restoring the original colors for peviously selected column header. Of course, all that code slows down the process. You may see a speed change in a sample form if you turn off most of the options.

Also the speed depends of complexity of Dynamic... expression which may be the case for custom group records highlighting.

Other than that it could be the underlying data which slow down the grid operation, as James noticed.
Nick Neklioudov
Universal Thread Consultant
3 times Microsoft MVP - Visual FoxPro

"I have not failed. I've just found 10,000 ways that don't work." - Thomas Edison
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform