As there's no built-in Interative Layer Control on MapSuite Desktop Edition, I am building one by myelf.
So far, everything is going OK, but now I want another feature that will support me to have a sort of "smart layer control".
The idea is that I want to get the styles that are visible within the current extent.
For example:
Let`s say I have one value based style that colors my shapes in 5 different colors, depending on a shape field: Green,Zellow,Pink,Black and Blue.
If I am seeing the full map extent, I want to show on my layer control all the 5 styles, based on the code you provided. But let`s say that I zoom in to an extent that will show me only 2 styles: Green and Blue.
What i want tis that the Map control gives me only the applied styles to the current extent, allowing me to show only Green and blue at that time.
How could I achieve that?
I tried to get some Infos from the OverlaysDrawn event, but I could not get only the drawn styles... I would not like to use QueryTools as this might create some Performance issues when map extent is too big(World extent, for example).. And on the other Hand, even if I get the drawn Features from the Feature source I will have one extra work to find out the applied styles to each Feature....
Anyone?
Regards,
PCBL