Example #1
0
        public void ProcessRequest(HttpContext context)
        {
            context.Response.ContentType = "text/html";

            using (StreamWriter writer = new StreamWriter(context.Response.OutputStream))
            {
                writer.WriteLine("<!DOCTYPE html>");

                OrgTreeNode root = OrgTreeNode.PreareOrgTree();

                TreeGraph graph = root.GenerateGraph();

                graph.WriteHtmlGraph(writer);
            }
        }
Example #2
0
        protected override void OnPreRender(EventArgs e)
        {
            OrgTreeNode root = OrgTreeNode.PreareOrgTree();

            TreeGraph graph = root.GenerateGraph();

            StringBuilder strB = new StringBuilder();

            using (StringWriter writer = new StringWriter(strB))
            {
                graph.WriteHtmlGraph(writer);
            }

            this.container.InnerHtml = strB.ToString();

            base.OnPreRender(e);
        }