Пример #1
0
        public Xero2ExcelWinForm(IExcelApplicationWrapper excelApplication, IServiceLocator serviceLocator)
        {
            InitializeComponent();

            _excelApplication = excelApplication;

            _configurationManager = serviceLocator.Get<IBindingConfigurationManager>();
            _connectionManager = serviceLocator.Get<IConnectionManager>();

            // Populate the list of interface names
            foreach (EntityBase entity in _configurationManager.GetRegisteredApiEntities())
            {
                interfaceNameCombobox.Items.Add(entity);
            }

            // Select the first item in the list
            if (interfaceNameCombobox.Items.Count > 0)
            {
                interfaceNameCombobox.SelectedIndex = 0;
            }
        }
Пример #2
0
        public Xero2ExcelWinForm(IExcelApplicationWrapper excelApplication, IServiceLocator serviceLocator)
        {
            InitializeComponent();

            _excelApplication = excelApplication;

            _configurationManager = serviceLocator.Get <IBindingConfigurationManager>();
            _connectionManager    = serviceLocator.Get <IConnectionManager>();

            // Populate the list of interface names
            foreach (EntityBase entity in _configurationManager.GetRegisteredApiEntities())
            {
                interfaceNameCombobox.Items.Add(entity);
            }

            // Select the first item in the list
            if (interfaceNameCombobox.Items.Count > 0)
            {
                interfaceNameCombobox.SelectedIndex = 0;
            }
        }