how to i choose on which "side" of the split will be the ExclusiveColumn ?
if for example i've done this :
ug.DisplayLayout.MaxColScrollRegions = 2;
ug.DisplayLayout.Bands[0].Columns[0].Header.ExclusiveColScrollRegion = ug.DisplayLayout.ColScrollRegions[0];
ug.DisplayLayout.Bands[1].Columns[0].Header.ExclusiveColScrollRegion = ug.DisplayLayout.ColScrollRegions[0];
ug.DisplayLayout.ColScrollRegions[0].Split();
the Column[0] of both bands is now exclusivly on the Right side of the split but i want it to be on the left side. where do i indicate that?
Furthermore,
How do i hide the Expand/Collapse indicators (+/- signs) from the one of the split sides? for example at the ExclusiveColScrollRegion ?
Hi,
It's hard to be sure, but the code you have here is assigning the ExclusiveColScrollRegion of column 0 in each band to the first ColScrollRegion - so that should be the one on the left. You are saying the column is only showing up on the right? That doesn't make sense.
sharik said:How do i hide the Expand/Collapse indicators (+/- signs) from the one of the split sides? for example at the ExclusiveColScrollRegion ?
There's no property for this. You could use a CreationFilter or a DrawFilter to hide them, but there will always be a space where they would have been.
i am not going to use ScrollRegiions but i thought to answer you, i also thought to my self, why would it go on the right side and not the left, but here is a screenshot. forgive my masking of data i know its silly.
the first col of the DataSet starts with "W" (on both DataTables) and that is the column which i made Exclusive (on both bands), and as you can see it is on the right side.
the RightToLeft property of the grid is set to NO (as by default) and the Anchor property is set to Top,Left (as by default) didn't touch these 2 properties. if you will like i will attach the project
Hi Paul,
This appears to be the same conversation we are having here:
Freezing Groups in WinGrid - NetAdvantage for Windows Forms - WinGrid
I have a grid that is comprised of many columns and a few row layout groups.
When I attempt to split it into two regions and force the first two columns to be exclusively in the first region, the second region is able to be scrolled onto those columns. So you end up seeing them twice. Once in the first region and again in the second one.
Here is my column freezing code:
private void FreezeColumns()
{
UltraGridLayout layout = ugManagers.DisplayLayout;
UltraGridBand band = layout.Bands[0];
int fixedWidth = 235;
layout.ColScrollRegions.Clear();
layout.MaxColScrollRegions = 2;
layout.ColScrollRegions[0].Split(fixedWidth);
layout.ColScrollRegions[0].Scrollbar = Scrollbar.Hide;
band.Columns[1].Header.ExclusiveColScrollRegion = layout.ColScrollRegions[0];
band.Columns[2].Header.ExclusiveColScrollRegion = layout.ColScrollRegions[0];
layout.ColScrollRegions[1].ScrollHeaderIntoView ( band.Columns[3].Header, true );
}
If there is a way for me to attach a few screenshots, I'd like to so you can see what's going on.
The first thing, I have to set the split size to 235 which is the combined width of my first two columns. I then assign both of them as exclusive to region 0. But when the grid displays, I am able to scroll the right side to the left and the first two solumns are seen. Why?
Thanks in advance,
Paul
No thanks :) all is well
Hello sharik,
Yes, this is the only solution I came to, also. I guess it is a designer's decision. If you like I could log a new Product Idea for you.
Thanks Boris,
I also did the same thing, basically some sort of reverse logic, if the Exclusive Column is static on the Right side instead of Left side, then to take all the rest of the columns excluding the one that i wanted on the Left and make them Exclusive Columns , this will put them on the Right side and keep the one i wanted on the Left to remain in the left.
but i still wonder how come Exclusive Columns are not set to the Right side by default, why left? as English is Left to Right. Come to think of it, the Fixed Headers does behave intuitivly as expected, the fixed columns are static on the Left and that what i would have expected from the Exclusive Columns feature.
Boris, thanks for all your support, you are all doing top quality work there :)