Drag and drop one datagridview contol to the form and do like this-
private void ShowDetails_Load(object sender, EventArgs e)
{
try
{
SqlConnection sqlconn = new SqlConnection("server=.\\sqlexpress;database=windowform;integrated security=true");
SqlDataAdapter da = new SqlDataAdapter("show", sqlconn);
da.SelectCommand.CommandType = CommandType.StoredProcedure;
DataSet ds = new DataSet();
da.Fill(ds);
dataGridView1.DataSource = ds.Tables[0];
}
catch(Exception ex)
{
MessageBox.Show(ex.Message);
}
}