设置最后一列的Width="*"
<DataGrid Name="dgBuild" ItemsSource="{Binding}" HorizontalScrollBarVisibility="Hidden" AutoGenerateColumns="False" CanUserReorderColumns="False" HeadersVisibility="None" GridLinesVisibility="All" HorizontalGridLinesBrush="#000" BorderThickness="1" IsReadOnly="True" >
<DataGrid.Columns >
<DataGridTextColumn Binding="{Binding ItemName}" />
<DataGridTextColumn Binding="{Binding Class}"/>
**<DataGridTextColumn Width="*" Binding="{Binding Data}"/>**
</DataGrid.Columns>
</DataGrid>