public void UpdateHtmlText(IHtmlTextInfo htmlTextInfo, int maximumVersionHistory)
        {
            if (htmlTextInfo == null)
            {
                throw new ArgumentNullException("htmlTextInfo");
            }

            Reflection.InvokeMethod(HtmlTextControllerType, "UpdateHtmlText", this.htmlTextController, new object[] { htmlTextInfo.HtmlTextInfoInstance, maximumVersionHistory });
        }
        public void UpdateHtmlText(IHtmlTextInfo htmlTextInfo, int maximumVersionHistory)
        {
            if (htmlTextInfo == null)
            {
                throw new ArgumentNullException("htmlTextInfo");
            }

            Reflection.InvokeMethod(HtmlTextControllerType, "UpdateHtmlText", this.htmlTextController, new object[] { htmlTextInfo.HtmlTextInfoInstance, maximumVersionHistory });
        }
        public void SaveHtmlContent(IHtmlTextInfo htmlTextInfo, int moduleId, int tabId, int portalId)
        {
            if (htmlTextInfo == null)
            {
                throw new ArgumentNullException("htmlTextInfo");
            }

            var workflowId = this.GetWorkflowId(moduleId, tabId, portalId);
            if (workflowId != null)
            {
                htmlTextInfo.WorkflowId = workflowId.Value;
                htmlTextInfo.StateId = this.GetFirstWorkflowStateId(workflowId.Value);
                this.UpdateHtmlText(htmlTextInfo, this.GetMaximumVersionHistory(portalId));
                return;
            }

            var module = new ModuleController().GetModule(moduleId, tabId, true);
            Reflection.InvokeMethod(HtmlTextControllerType, "SaveHtmlContent", this.htmlTextController, new object[] { htmlTextInfo.HtmlTextInfoInstance, module, });
        }