I'm new to C#. I trying to develop WPF application. In here when I press Save button I want to refresh the all the text box after insert values to database. How can I do that? Thanks..
addnewcategory.xaml.cs
    public addnewcategory()
    {
        InitializeComponent();
    }
    private void save_Click(object sender, RoutedEventArgs e)
    {
        string dbConn = "datasource=localhost;port=3306;username=root";
        string Query = "insert into tenderprocess.mstcategory (category) values('" + this.txtcategory.Text + "');";
        MySqlConnection mysqlConn = new MySqlConnection(dbConn);
        MySqlCommand cmdTenderprocess = new MySqlCommand(Query, mysqlConn);
        MySqlDataReader myReader;
        try
        {
            mysqlConn.Open();
            myReader = cmdTenderprocess.ExecuteReader();
            MessageBox.Show("New Category Successfully Saved");
            while (myReader.Read())
            {
            }
        }
        catch (Exception ex)
        {
            MessageBox.Show(ex.Message);
        }
    }
}
}
 
    