Exemplo n.º 1
0
 /// <summary>
 /// 显示SAP Query控件
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void tgbtnQuery_Click(object sender, RibbonControlEventArgs e)
 {
     if (_SapQueryPane == null)
     {
         _SAPQueryControl              = new SAPQueryControl();
         _SapQueryPane                 = Globals.ThisAddIn.CustomTaskPanes.Add(_SAPQueryControl, "SAP Query");
         _SapQueryPane.DockPosition    = Microsoft.Office.Core.MsoCTPDockPosition.msoCTPDockPositionBottom;
         _SapQueryPane.VisibleChanged += new System.EventHandler(_SapQueryPane_VisibleChanged);
         _SapQueryPane.Visible         = true;
     }
     else
     {
         _SapQueryPane.Visible = ((RibbonToggleButton)sender).Checked;
     }
 }
        /// <summary>
        /// 显示SAP Query控件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void tgbtnQuery_Click(object sender, RibbonControlEventArgs e)
        {
            if (_SapQueryPane == null)
            {
                _SAPQueryControl = new SAPQueryControl();
                _SapQueryPane = Globals.ThisAddIn.CustomTaskPanes.Add(_SAPQueryControl, "SAP Query");
                _SapQueryPane.DockPosition = Microsoft.Office.Core.MsoCTPDockPosition.msoCTPDockPositionBottom;
                _SapQueryPane.VisibleChanged += new System.EventHandler(_SapQueryPane_VisibleChanged);
                _SapQueryPane.Visible = true;
            }
            else
            {

                _SapQueryPane.Visible = ((RibbonToggleButton)sender).Checked;
            }
        }