Please Help ! C# WPF Row height cannot increase automatically by NaN value
Posted by: Su-Sang Lee
Date: January 10, 2016 01:46AM

Hello,

I've been crazily exhausted in finding solution for several hours on internet but failed. Therefore, I'm sending MayDay SOS to here...

I connected MySQL database to WPF DataGrid through below simple code. However, when I run the applicaiton, the DataGrid show only same height rows with cut content not fully shown eventhough the property of row height of DataGrid is NaN.

Why NaN value doesn't work? Is there any alternative solution to bypass this situation?

Because I have big limitation that my major is totally different from software programming but biochemistry....Solving by myself is almost impossible though I already tried my best and exhausted deadly..

Please, Please I would much highly appreciate if somebody share highly excellent insights of programming......

Thank you so much !

My best regard

private void datagridbind()[enter image description here][1]
{
MySqlConnection Conn = new MySqlConnection();
Conn.ConnectionString = myConnectionString;
Conn.Open();

try
{
string sql = "SELECT name_basic, visitdate_basic, majorcomplain_basic, majorsolution_basic,dialogue_basic,memonote_basic FROM user";
MySqlCommand comm = new MySqlCommand(sql, Conn);
comm.ExecuteNonQuery();

MySqlDataAdapter da = new MySqlDataAdapter(comm);
DataTable dt = new DataTable("user");
da.Fill(dt);
dataGrid.ItemsSource = dt.DefaultView;
da.Update(dt);
dataGrid.ScrollIntoView(CollectionView.NewItemPlaceholder);
Conn.Close();

}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}


}

Options: ReplyQuote


Subject
Written By
Posted
Please Help ! C# WPF Row height cannot increase automatically by NaN value
January 10, 2016 01:46AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.