In a textbox I have to write a name that is in the database, when clicking the button has to load data in the gridview, then I added the textbox. I have the following query, I have to display the records in a gridview but I mark this error, "The input string is not formatted correctly."
I have parameters in string and an integer
AppData.DataSet1TableAdapters.PS_USR_ConsultaExternaTableAdapter adapter = new AppData.DataSet1TableAdapters.PS_USR_ConsultaExternaTableAdapter();
adapter.GetData("", "", "", int.Parse(this.TextBox1.Text));
this.gvbuscar.DataSource = adapter.GetData("", "", "", int.Parse(this.TextBox1.Text));
this.gvbuscar.DataBind();