Ejemplo n.º 1
0
        public static string removeViewState(ActivityBuilder activityBuilder)
        {
            string xamlString = "";

            XmlWriterSettings writerSettings = new XmlWriterSettings {
                Indent = true
            };

            StringBuilder stringBuilder = new StringBuilder();


            XmlWriter xmlWriter = XmlWriter.Create(stringBuilder, writerSettings);

            XamlXmlWriter xamlXmlWriter = new XamlXmlWriter(xmlWriter, new XamlSchemaContext());

            XamlWriter xamlWriter = ActivityXamlServices.CreateBuilderWriter(xamlXmlWriter);

            viewStateXamlWriter wfViewStateControl = new viewStateXamlWriter(xamlWriter);

            XamlServices.Save(wfViewStateControl, activityBuilder);

            xamlString = stringBuilder.ToString();

            return(xamlString);
        }
Ejemplo n.º 2
0
        public static string removeViewState(ActivityBuilder activityBuilder)
        {
            string xamlString = "";

            XmlWriterSettings writerSettings = new XmlWriterSettings { Indent = true };

            StringBuilder stringBuilder = new StringBuilder();

            XmlWriter xmlWriter = XmlWriter.Create(stringBuilder, writerSettings);

            XamlXmlWriter xamlXmlWriter = new XamlXmlWriter(xmlWriter, new XamlSchemaContext());

            XamlWriter xamlWriter = ActivityXamlServices.CreateBuilderWriter(xamlXmlWriter);

            viewStateXamlWriter wfViewStateControl = new viewStateXamlWriter(xamlWriter);

            XamlServices.Save(wfViewStateControl, activityBuilder);

            xamlString = stringBuilder.ToString();

            return xamlString;
        }