public void Open(TEditSidebar ts)
 {
     this.sidebar = ts;
     this.Clone2.IsChecked = true;
     this.tbCloneName.Text = ts.tbTemplateName.Text + "-Copy";
     this.tbCloneName.IsEnabled = true;
     this.txtPrepend.Text = "Copy";
 }
Пример #2
0
        // Open from the Template Sidebar
        public void Open(TemplateEdit.TEditSidebar ts,string ConceptId, string Html, string pbType)
        {
            this.TemplateSideBar = ts;
            this.HasChanged = false;
            this.Open(ConceptId, Html, pbType);

            this.btnEdit.Visibility = System.Windows.Visibility.Visible;
            this.btnFootnotes.Visibility = System.Windows.Visibility.Visible;
        }
Пример #3
0
        private void AddAwesomeAxiomTaskPane(Word.Document doc)
        {
            this.SetRibbon();

            // WPF Form
            if (isTemplate() || isExportTemplate() || isClause())
            {

                System.Windows.Forms.Integration.ElementHost elHost = new System.Windows.Forms.Integration.ElementHost();
                TemplateEdit.TEditSidebar tsb = new TemplateEdit.TEditSidebar(doc);
                elHost.Child = tsb;
                elHost.Dock = System.Windows.Forms.DockStyle.Fill;
                System.Windows.Forms.UserControl u = new System.Windows.Forms.UserControl();
                u.Controls.Add(elHost);
                Microsoft.Office.Tools.CustomTaskPane taskPaneValue = Globals.ThisAddIn.CustomTaskPanes.Add(u, "Axiom IRIS Template", doc.ActiveWindow);
                taskPaneValue.Visible = true;
                taskPaneValue.Width = 300;
                taskPaneValue.VisibleChanged += new EventHandler(taskPaneValue_VisibleChanged);

            }
            else if (isContract() || isUnAttachedContract())
            {

                ElementHost elHost = new ElementHost();
                ContractEdit.SForceEditSideBar2 csb = new ContractEdit.SForceEditSideBar2();
                elHost.Child = csb;
                elHost.Dock = DockStyle.Fill;
                System.Windows.Forms.UserControl u = new System.Windows.Forms.UserControl();
                u.Controls.Add(elHost);
                Microsoft.Office.Tools.CustomTaskPane taskPaneValue = this.CustomTaskPanes.Add(u, "Axiom IRIS Contract", doc.ActiveWindow);
                taskPaneValue.Visible = true;
                taskPaneValue.Width = 400;
                taskPaneValue.VisibleChanged += new EventHandler(taskPaneValue_VisibleChanged);

            }
        }
Пример #4
0
        // Open from the Contract Sidebar
        public void OpenFromContract(string ConceptId, string Html, string pbType)
        {
            this.TemplateSideBar = null;
            this.HasChanged = false;
            this.Open(ConceptId, Html, pbType);

            this.btnEdit.Visibility = System.Windows.Visibility.Hidden;
            this.btnFootnotes.Visibility = System.Windows.Visibility.Hidden;
        }