Ok, so I am opening a new topic with this issue
Hi, I am MarkoI am having a problem understanding how this works:http://samples.infragistics.com/sllob/RunSamples.aspx?cn=grid#/grid/handling-hierarchical-data-setsCan someone please put here some sample project with Access database (I am using SQL 2008) so that I can see how do I get data from the database into the class objects and the into grid. I am asking this cause I can't understand this part with binding data to the columns:Text="{Binding Source={StaticResource Strings} , Path=XWG_OrderDetails_Discount}"This is how I load data into grid from database: I make new class "Users" and make method in service "GetUsers" that executes sql query and gets data from db onto list of objects of "Users" class and returns that list. When execution of the service method is completed I do this xamGrid1.ItemsSource = e.Result; and grid displays data.How is this "http://samples.infragistics.com/sllob/RunSamples.aspx?cn=grid#/grid/handling-hierarchical-data-sets" different ? comparing to the my method described above??
PS. Can someone please put here some sample project with Access database.
Please help me resolve this issue,Best regards,Marko
Hi, EkStaneva
I didn't resolved this issue yet. I have tried using RowHeight="Dynamic" but when I use it I get the gap between rows again.
Did you had any luck resolving this issue??
Anybody knows how to overcome this problem?
Regards,
Marko.
Or just to simplify the question:
Can some row have it's own independent height ("Auto") if RowHeight property is set on the grid level to some value?
Can RowHeight be set for each row separately?? So maybe I can adjust it during InitializeRow event ??
I didn't resolved this issue yet.
Best regards.
Hi.
I have managed to remove that gap between expansion indicator cells. It was my mistake in the first place, sorry.
Problem was that I left RowHeight property of xamGrid to 23px (and this height applies to expander indicator column also):
<ig:XamGrid x:Name="xamGridAktivnosti" HorizontalAlignment="Left" VerticalAlignment="Top" Grid.Column="0" Grid.Row="2" MaxWidth="1062" Width="1062" RowHeight="23" CellStyle="{StaticResource xamGreen}" AutoGenerateColumns="False" IsAlternateRowsEnabled="False">
When I set RowHeight to 14px rows come up nice without gap between them or between the expansion indicator cells see::
As you can see now I have a problem. If I don't use RowHeight property I get a gap between expansion indicator cells, and if I use RowHeight property then there is no gap but then not all text is visible in the sub row when I expand (as you can see - selected sub row on the picture). It should be 4 or 5 lines of text but I can see only one. Here is the xaml:
<ig:ColumnLayout Key="listKomentarTitles" ColumnLayoutHeaderVisibility="Never" HeaderVisibility="Collapsed" > <ig:ColumnLayout.Columns> <ig:TextColumn Key="NASLOV" HeaderText="Log tiketa" /> <ig:ColumnLayout Key="KOMENTARTEXT" ColumnLayoutHeaderVisibility="Never" HeaderVisibility="Collapsed" > <ig:ColumnLayout.Columns> <ig:TextColumn Key="TEXT" TextWrapping="Wrap" HeaderText="Komentar" /> </ig:ColumnLayout.Columns> </ig:ColumnLayout> </ig:ColumnLayout.Columns> </ig:ColumnLayout>
.. as you can see TextWrapping is turned on. I set the style like so:
Style styleKomentarText = new Style(typeof(CellControl)); styleKomentarText.Setters.Add(new Setter(CellControl.WidthProperty, "Auto"));styleKomentarText.Setters.Add(new Setter(CellControl.HeightProperty, "Auto")); styleKomentarText.Setters.Add(new Setter(CellControl.PaddingProperty, "0,0")); styleKomentarText.Setters.Add(new Setter(CellControl.FontFamilyProperty, new FontFamily("Arial"))); styleKomentarText.Setters.Add(new Setter(CellControl.FontSizeProperty, "11")); styleKomentarText.Setters.Add(new Setter(CellControl.VerticalAlignmentProperty, "Top")); styleKomentarText.Setters.Add(new Setter(CellControl.VerticalContentAlignmentProperty, "Center")); styleKomentarText.Setters.Add(new Setter(CellControl.CursorProperty, "Hand")); styleKomentarText.Setters.Add(new Setter(CellControl.FontStretchProperty, "SemiCondensed")); e.Row.CellStyle = styleKomentarText;
Please help what do I do? I must use RowHeight but I also must have that sub row to hold huge amount of text. It's height has to depend of the amount of text that loads into that sub row (1 column):
<ig:TextColumn Key="TEXT" TextWrapping="Wrap" />
Hello Marko,
I have been looking into your new question and you can set the xamGrid’s RowHeight property to 14 in order to make it as big as the CellControl’s height, so there will be no empty space between the CellsPanel and the underlying CellControl that you have re-template.
Please let me know if my know if you require any further assistance.
Sincerely,
Ekaterina
Developer Support Engineer
Infragistics, Inc.
www.infragistics.com/support
Hi
I have visited the link you posted http://forums.infragistics.com/forums/p/67378/341050.aspx and also I have downloaded that project xamCalendar_setColorToDay.zip. I have opened that project but there is no xamGrid with expansion indicator cells in it. I have read that thread and looked trought that sample project but I couldn't find anything that I could use to help me solve my issue.
In my project here is how I wrote at the end of my xamGrid:
<ig:XamGrid.ExpansionIndicatorSettings> <ig:ExpansionIndicatorSettings> <ig:ExpansionIndicatorSettings.Style> <Style TargetType="Prim:ExpansionIndicatorCellControl"> <Setter Property="Height" Value="14"/> <Setter Property="Padding" Value="0" /> <Setter Property="MaxHeight" Value="14" /> <Setter Property="Margin" Value="0" /> </Style> </ig:ExpansionIndicatorSettings.Style> </ig:ExpansionIndicatorSettings> </ig:XamGrid.ExpansionIndicatorSettings>
Should this be enough? ... I have clearly specified height of expansion indicator cells to be 14px , padding to be 0px margin to be 0px . But all that had no effect.
I don't know what to do next?
Best regards,