get this error when i open a url
Cannot use a leading .. to exit above the top directory.
my code in global.asax is :- void RegisterRoutes(RouteCollection routes)
{
routes.MapPageRoute("Home", "Home", "~/index.aspx");
routes.MapPageRoute("About", "About", "~/About.aspx");
routes.MapPageRoute("Client", "Client", "~/Client.aspx");
routes.MapPageRoute("Career", "Career", "~/Career.aspx");
routes.MapPageRoute("Contact", "Contact", "~/Contact.aspx");
routes.MapPageRoute("Product", "Product/{SID}/{SubCategory}", "~/Product.aspx"); --> on this i get this error.
}
link on master page :-
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
GetProducts();
}
}
public void GetProducts()
{
DataSet Nteturn;
Nteturn = SqlHelper.ExecuteDataset(SqlHelper.GetConnection(), CommandType.StoredProcedure, "SP_Product"
, SqlHelper.CreatePerameter("@Action", SqlDbType.NVarChar, "Show_Product", ParameterDirection.Input, 100000, false)
, SqlHelper.CreatePerameter("@SID", SqlDbType.NVarChar, Request.QueryString["SID"], ParameterDirection.Input, 100000, false)
);
if (Nteturn.Tables[0].Rows.Count > 0)
{
rptproduct.DataSource = Nteturn.Tables[0];
rptproduct.DataBind();
lblcat.Text = Nteturn.Tables[0].Rows[0]["Main_Category"].ToString();
lblsubcat.Text = Nteturn.Tables[0].Rows[0]["Sub_Category"].ToString();
}
}
Please help me to solve this problem
Susanta RoutPosted Mar 28, 2018, 5:49 AM
Suggested Posts
Nanddeep NachanPosted Mar 26, 2018, 10:08 AM