Creating an Additional Custom Button Panel

<< Click to Display Table of Contents >>

Navigation:  Developers' Guide > Customizing User Interface > FAQs > Samples >

Creating an Additional Custom Button Panel

Navigation: Developers' Guide > Customizing User Interface > FAQs > Samples >

hm_btn_navigate_prevhm_btn_navigate_tophm_btn_navigate_next

Creating an Additional Custom Button Panel

 

Show/Hide Hidden Text

This topic demonstrates how to create additional custom button panel in Management Console (MC).

Click here to collapse/expand the view.

Sample for Creating Additional Custom Button Panel.

using System;

using System.Collections.Generic;

using System.Linq;

using System.Text;

using System.Threading.Tasks;

using CXS.Retail.Extensibility;

using CXS.Retail.Extensibility.Modules.BusinessPartner;//for inheriting VendorViewModuleBase 

using CXS.Platform.UIComponents;//For adding custom CXSbutton

using CXS.Retail.UIComponents;//For vendorSearchview screen

using DevExpress.XtraEditors;

//using CXS.Framework.Core;

//using CXS.Retail.ManagementUIComponents;

using System.Windows.Forms;

 

 

namespace SampleAddOn

{

    class CustomButtonPanelOnVendorSearchScreen:VendorViewModuleBase

    {

        //Intialized event for VendorAddEdit screen

        public override void OnViewIntialized(object sender, ViewInitializedEventArgs args)

        {

            //get VendorAddEdit screen 

            VendorAddEditView m_VendorView = sender as VendorAddEditView;

 

               //Add custom button to VendorAddEdit screen.

               //Note: we can add max 12 custom button.

                CXSButton m_CXSButton1 = m_VendorView.AddCustomButton("Custom button 1 ");

                CXSButton m_CXSButton2 = m_VendorView.AddCustomButton("Custom button 2 ");

                CXSButton m_CXSButton3 = m_VendorView.AddCustomButton("Custom button 3 ");

                CXSButton m_CXSButton4 = m_VendorView.AddCustomButton("Custom button 4 ");

                CXSButton m_CXSButton5 = m_VendorView.AddCustomButton("Custom button 5 ");

                CXSButton m_CXSButton6 = m_VendorView.AddCustomButton("Custom button 6 ");

                CXSButton m_CXSButton7 = m_VendorView.AddCustomButton("Custom button 7 ");

                CXSButton m_CXSButton8 = m_VendorView.AddCustomButton("Custom button 8 ");

                CXSButton m_CXSButton9 = m_VendorView.AddCustomButton("Custom button 9 ");

                CXSButton m_CXSButton10 = m_VendorView.AddCustomButton("Custom button 10 ");

                CXSButton m_CXSButton11 = m_VendorView.AddCustomButton("Custom button 11");

                CXSButton m_CXSButton12 = m_VendorView.AddCustomButton("Custom button 12");

 

                m_CXSButton1.Click += m_CXSButton1_Click;

                m_CXSButton2.Click += m_CXSButton2_Click;

                m_CXSButton3.Click += m_CXSButton3_Click;

                m_CXSButton4.Click += m_CXSButton4_Click;

                m_CXSButton5.Click += m_CXSButton5_Click;

                m_CXSButton6.Click += m_CXSButton6_Click;

                m_CXSButton7.Click += m_CXSButton7_Click;

                m_CXSButton8.Click += m_CXSButton8_Click;

                m_CXSButton9.Click += m_CXSButton9_Click;

                m_CXSButton10.Click += m_CXSButton10_Click;

                m_CXSButton11.Click += m_CXSButton11_Click;

                m_CXSButton12.Click += m_CXSButton12_Click; 

        }

 

        //Click event for custom button m_CXSButton1

        private void m_CXSButton1_Click(object sender, EventArgs e)

        {

            MessageBox.Show("Custom button 1 clicked!!");

        }

 

        //Click event for custom button m_CXSButton2

        private void m_CXSButton2_Click(object sender, EventArgs e)

        {

            MessageBox.Show("Custom button 2 clicked!!");

        }

 

        //Click event for custom button m_CXSButton3

        private void m_CXSButton3_Click(object sender, EventArgs e)

        {

            MessageBox.Show("Custom button 3 clicked!!");

        }

 

        //Click event for custom button m_CXSButton4

        private void m_CXSButton4_Click(object sender, EventArgs e)

        {

            MessageBox.Show("Custom button 4 clicked!!");

        }

 

        //Click event for custom button m_CXSButton5

        private void m_CXSButton5_Click(object sender, EventArgs e)

        {

            MessageBox.Show("Custom button 5 clicked!!");

        }

 

        //Click event for custom button m_CXSButton6

        private void m_CXSButton6_Click(object sender, EventArgs e)

        {

            MessageBox.Show("Custom button 6 clicked!!");

        }

 

        //Click event for custom button m_CXSButton7

        private void m_CXSButton7_Click(object sender, EventArgs e)

        {

            MessageBox.Show("Custom button 7 clicked!!");

        }

 

        //Click event for custom button m_CXSButton8

        private void m_CXSButton8_Click(object sender, EventArgs e)

        {

            MessageBox.Show("Custom button 8 clicked!!");

        }

 

        //Click event for custom button m_CXSButton9

        private void m_CXSButton9_Click(object sender, EventArgs e)

        {

            MessageBox.Show("Custom button 9 clicked!!");

        }

 

        //Click event for custom button m_CXSButton10

        private void m_CXSButton10_Click(object sender, EventArgs e)

        {

            MessageBox.Show("Custom button 10 clicked!!");

        }

        //Click event for custom button m_CXSButton11

        private void m_CXSButton11_Click(object sender, EventArgs e)

        {

            MessageBox.Show("Custom button 11 clicked!!");

        }

 

        //Click event for custom button m_CXSButton12

        private void m_CXSButton12_Click(object sender, EventArgs e)

        {

            MessageBox.Show("Custom button 12 clicked!!");

        }

    }

}