This is a migrated thread and some comments may be shown as answers.

dynamic sdk:datagrid issue

1 Answer 35 Views
GridView
This is a migrated thread and some comments may be shown as answers.
JanwalkarPooja
Top achievements
Rank 2
JanwalkarPooja asked on 13 May 2014, 07:55 AM
Hi,

In my project dynamically generated  sdk:datagrid creating  problem.Whenever I'm adjusting data grid columns simultaneously next other controls(Error-grid and buttons) also get moved(not get properly aligned).
I don't want this type of behaviour.
Kindly look into this issue as soon as possible.
Looking forward your reply.

Following is given code line:
 <toolkit:BusyIndicator  IsBusy="{Binding Path=IsBusy, Mode=TwoWay}"  BusyContent="{Binding Path=BusyContent, Mode=TwoWay}" >
            <Grid x:Name="LayoutRoot" Margin="0,0,0,0" Height="420" MaxWidth="1030">
                <StackPanel x:Name="DynamicDataGrid" Orientation="Horizontal" Margin="0,0,0,0" Height="400" UseLayoutRounding="False" d:LayoutRounding="Auto">
                    <StackPanel.RenderTransform>
                        <CompositeTransform Rotation="0.08"/>
                    </StackPanel.RenderTransform>
                    <sdk:DataGrid x:Name="DynamicGrid" ItemsSource="{Binding xxx}" FrozenColumnCount="{Binding FrozenColumns}" FontSize="11" RowHeight="25" Foreground="grey"  AutoGenerateColumns="False" Height="350" MaxWidth="1030" HorizontalAlignment="Left" ScrollViewer.HorizontalScrollBarVisibility="Auto" ScrollViewer.VerticalScrollBarVisibility="Visible" Margin="0,-50,0,0" />
                    <Grid x:Name="Error"  Margin="-845,350,0,0"  HorizontalAlignment="Stretch"  Height="50">
                    <!--<StackPanel x:Name="Error"    Margin="-845,350,0,0"  Height="50">-->
                        <TextBlock Text="Note: * indicates error " Foreground="red" Height="18" />
                        <TextBlock  Text="{Binding ErrorMessage}" Foreground="Green" Height="20"/>
                    <!--</StackPanel>-->
                    </Grid>
                </StackPanel>
                <Grid  x:Name="buttons"  HorizontalAlignment="Right" Margin="170,385,0,0" MaxWidth="1030"   Height="33">
                    <Grid.RowDefinitions>
                        <RowDefinition/>
                    </Grid.RowDefinitions>
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition/>
                        <ColumnDefinition/>
                        <ColumnDefinition/>
                    </Grid.ColumnDefinitions>
                    <!--<StackPanel x:Name="buttons" Orientation="Horizontal" HorizontalAlignment="Left" Margin="170,385,0,0" Width="850" Height="33">-->
                    <Button x:Name="01" Grid.Column="0" IsEnabled="{Binding xx, Mode=TwoWay}" Content="zzz"   Height="25" Width="80" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="0,0,0,0" Command="{Binding AddNewEntityRecord}" CommandParameter="{Binding ElementName=DynamicGrid}" />
                        <Button x:Name="02" Grid.Column="1" IsEnabled="{Binding xx, Mode=TwoWay}" Content="aaa"  Height="25" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center" Margin="5,0,0,0"  Command="{Binding SaveRows}" CommandParameter="{Binding ElementName=DynamicGrid}" />
                        <Button x:Name="03" Grid.Column="2" IsEnabled="{Binding xx, Mode=TwoWay}" Content="sss"  Height="25" Width="80" VerticalAlignment="Center" HorizontalAlignment="Center" Margin="5,0,0,0"  Command="{Binding DeleteRows}" CommandParameter="{Binding ElementName=DynamicGrid}" />
                    <!--</StackPanel>-->
                </Grid>
            </Grid>

Thanks and regards,
Pooja

       



1 Answer, 1 is accepted

Sort by
0
JanwalkarPooja
Top achievements
Rank 2
answered on 16 May 2014, 12:07 PM
This issue is resolved now, :)  :)
Tags
GridView
Asked by
JanwalkarPooja
Top achievements
Rank 2
Answers by
JanwalkarPooja
Top achievements
Rank 2
Share this question
or