public partial class WebForm1 : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
string cs = ConfigurationManager.ConnectionStrings["DBS"].ConnectionString;
SqlConnection conn = new SqlConnection(cs);
SqlCommand cmd = new SqlCommand("Select * From route", conn);
conn.Open();
GridView1.DataSource = cmd.ExecuteReader();
GridView1.DataBind();
conn.Close();
}
}
here is the error !!!
Server Error in '/' Application.
The system cannot find the file specified
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.Exception Details: System.ComponentModel.Win32Exception: The system cannot find the file specified
Source Error:
|
Source File: c:\Users\ZEESHAN\Documents\Visual Studio 2013\Projects\ADOTUTS\ADOTUTS\WebForm1.aspx.cs Line: 19
Rajkiran SwainPosted Jun 18, 2017, 4:15 AM
Amit GuptaPosted Jun 18, 2017, 2:56 AM
Sundaram SubramanianPosted Jun 18, 2017, 2:03 AM