Ejemplo n.º 1
0
        private void ui_buttonX_shareConnect_Click(object sender, EventArgs e)
        {
            if (DataExportClientDataManager.CurrentDbIsShared) return;

            DataExportClientDataManager.ConnectToShareDb(_connectionToSharedDb, _client.UserID);
            _client.ConnectedToSharedDb = true;
            _client.ConnectedToLocalDb = false;

            RefreshProfiles();
            RefreshSymbols();
            ClearAllQueryUi();
            Refresh();

            if(_exportJobs != null)
            {
                _exportJobs = new ScheduleTimer();
            }
            LoadJobs();
        }
Ejemplo n.º 2
0
        private void ui_buttonX_localConnect_Click(object sender, EventArgs e)
        {
            if (DataExportClientDataManager.IsConnected() && !DataExportClientDataManager.CurrentDbIsShared) return;

            var dbName = ui_home_textBoxX_db.Text;
            var host = ui_home_textBoxX_host.Text;
            var usName = ui_home_textBoxX_uid.Text;
            var passw = ui_home_textBoxX_pwd.Text;
            _connectionToLocalDb = "SERVER=" + host + "; DATABASE=" + dbName + "; UID=" + usName + "; PASSWORD=" + passw;

            DataExportClientDataManager.ConnectToLocalDb(_connectionToLocalDb, _client.UserID);
            _client.ConnectedToSharedDb = false;
            _client.ConnectedToLocalDb = true;

            RefreshProfiles();
            RefreshSymbols();
            ClearAllQueryUi();
            Refresh();

            if (_exportJobs != null)
            {
                _exportJobs = new ScheduleTimer();
            }
            LoadJobs();
        }