Click here to Skip to main content
15,867,923 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am populating a grdiview in wpf

Check the image below

http://postimg.org/gallery/2n8yhoubi/ab28f5ae/

But the gridview align is not proper how can i make to fit properly.

HTML
<Grid Visibility="Visible" HorizontalAlignment="Stretch" Margin="5,5,5,0" x:Name="gdvDiagnosis" Width="Auto"
             Grid.Column="1" Grid.Row="4" ScrollViewer.CanContentScroll="True"
             ScrollViewer.HorizontalScrollBarVisibility="Auto" ScrollViewer.VerticalScrollBarVisibility="Auto" Height="Auto" VerticalAlignment="Stretch" Grid.RowSpan="2">
           <Grid.ColumnDefinitions>
               <ColumnDefinition Width="0*"/>
               <ColumnDefinition Width="*"/>
               <ColumnDefinition Width="0*"/>
           </Grid.ColumnDefinitions>
           <Grid.RowDefinitions>
               <RowDefinition Height="0"/>
               <RowDefinition Height="0.43*"/>
               <RowDefinition Height="8.071"/>
               <RowDefinition Height="0.485*"/>
               <RowDefinition Height="0.085*"/>
           </Grid.RowDefinitions>
Posted
Comments
ashok rathod 6-Oct-14 7:22am    
can you post here your problem ? as i am not able to see the image
chandra sekhar 6-Oct-14 9:27am    
Access this path you can see the image http://postimg.org/gallery/2ic4ecb04/079554c8
ashok rathod 7-Oct-14 2:17am    
Dear chandra sekhar above domain is blocked in our environment so not able to see the image,

1 solution

Hello Chandra I would suggest you to go with the Width and Height of your ColumnDefinition and RowDefinition as either Auto or with Start in numeric values like 1*, 2* etc.

Making height in 0.43* will create problems in your alignment.

I would suggest you to stick to Auto as height width if you are sure that your content width should be fix.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900