protected void Page_Load(object sender, EventArgs e) { try { if (String.IsNullOrEmpty(Request.QueryString["q"])) { LoadDocument(); } else { SearchDocumentByTagName(); } } catch (IndexOutOfRangeException ex) { ErrorLoging.WriteLog(String.Format("Message: {0}\nTarget: {1}\nDetails: {2}", ex.Message, ex.TargetSite, ex.StackTrace), System.Diagnostics.EventLogEntryType.Error); } catch (NullReferenceException ex) { ErrorLoging.WriteLog(String.Format("Message: {0}\nTarget: {1}\nDetails: {2}", ex.Message, ex.TargetSite, ex.StackTrace), System.Diagnostics.EventLogEntryType.Error); } catch (Exception ex) { ErrorLoging.WriteLog(String.Format("Message: {0}\nTarget: {1}\nDetails: {2}", ex.Message, ex.TargetSite, ex.StackTrace), System.Diagnostics.EventLogEntryType.Error); Response.Redirect("error.aspx"); } }
protected void Page_Load(object sender, EventArgs e) { //DocumentRatingModel rating = new DocumentRatingModel(); //rating.DocumentAverageRate(2); ErrorLoging.WriteLog("test phat", System.Diagnostics.EventLogEntryType.Information); //DocumentModel docModel = new DocumentModel(); //CallMethodByText(docModel, "GetDocumentById", new object[] { 2 }); //Testing(docModel.GetType(), docModel); //dynamic dym = CallMethodByString("BusinessLogicLayer.DocumentModel", "GetDocumentList"); //String path = new Uri("http://*****:*****@"(page=)\d{1,9}"); String s = rg.Replace(Request.Url.OriginalString, "page=4"); }