Exemplo n.º 1
0
        /// <summary>
        /// Get Page As Html string
        /// </summary>
        /// <param name="inUrl"></param>
        /// <param name="inServer"></param>
        /// <returns></returns>
        public static string getPageAsHtml(string inUrl, HttpServerUtility inServer)
        {
            // get the html string for the report
            StringWriter htmlStringWriter = new StringWriter();

            inServer.Execute(inUrl, htmlStringWriter);
            string htmlCodeToConvert = htmlStringWriter.GetStringBuilder().ToString();

            htmlStringWriter.Close();
            return(htmlCodeToConvert);
        }
Exemplo n.º 2
0
        public String applyTemplate(object obj)
        {
            if (this.hasTemplate())
            {
                System.IO.StringWriter htmlStringWriter = new System.IO.StringWriter();

                Server.Execute("Templates/" + configuration["template"] + "", htmlStringWriter);
                string htmlOutput = htmlStringWriter.GetStringBuilder().ToString();
                return(htmlOutput);
            }
            return(obj.ToString());
        }
 public override void Execute(string path)
 {
     _httpServerUtility.Execute(path);
 }
Exemplo n.º 4
0
 public override void Execute(string path)
 {
     _server.Execute(path);
 }
 public void Execute_String_Deny_Unrestricted()
 {
     hsu.Execute(String.Empty);
 }