Hi, is it possible to select cells in XamDataGrid by holding the left button and dragging? If not, is it possible to simulate this somehow? Thank you for any answer.
Lukas
Hello Lukas,
Thank you for your feedback. I am glad that you resolved your issue and I believe that other community members may benefit from this as well.
Thanks again.
Ok I solved it with help of this post http://ko.infragistics.com/community/forums/t/77613.aspx . Template override whole template of cell. Define ContentTemplate is much more better.
<Style x:Key="statCellTemplate" TargetType="igDP:CellValuePresenter"> <Setter Property="ContentTemplate"> <Setter.Value> <DataTemplate> <TextBlock Text="{Binding Value}" /> </DataTemplate> </Setter.Value> </Setter> </Style>
Ok I found what is wrong. I am using Style for CellValuePresenter:
<Style x:Key="CellStyle" TargetType="igDP:CellValuePresenter" BasedOn="{x:Static igThemes:DataPresenterOffice2010Blue.CellValuePresenter}"> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type igDP:CellValuePresenter}"> <TextBlock Text="{Binding RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type igDP:CellValuePresenter}}, Path=Value}" Background="Transparent" /> </ControlTemplate> </Setter.Value> </Setter> </Style>
But now I can't see cells that should be selected. Is there a way around this?