Click here to Skip to main content
15,892,161 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Code :
Page1.Xmal
HTML
<sdk:DataGrid Height="211"  HorizontalAlignment="Left" Margin="116,195,0,0" Name="dg" VerticalAlignment="Top" Width="846" SelectionChanged="dg_SelectionChanged" />


Page1.Xaml.cs
C#
dg.ItemsSource = e.Result;

"Via Wcf Service (linq to sql)"

How can I remove a column from a datagrid while the data is from sql database
+

I have 6 items in sqltable so i want do add purchase button next to each item how can i do this ?

Thank In advance
Posted
Updated 28-Dec-11 20:39pm
v2

Hope this help :
HTML
<DataGrid AutoGenerateColumns="False" >                                      
  <DataGrid.Columns>                    
   <DataGridTextColumn Header="myField" Binding="{Binding myField}" />                               
  </DataGrid.Columns>                
</DataGrid>
 
Share this answer
 
v2

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