Esempio n. 1
0
 public void Disconnect()
 {
     if (cv != null)
     {
         cv.close();
     }
     if (svr != null && svr.isConnected())
     {
         svr.disconnect();
     }
     if (ess != null && ess.isSignedOn())
     {
         ess.signOff();
     }
 }
Esempio n. 2
0
 private void btnConnect_Click(object sender, EventArgs e)
 {
     try
     {
         essApp = ((String)((String[])(cboAppDB.SelectedItem.ToString().Split('|')))[0]).Trim();
         essDB  = ((String)((String[])(cboAppDB.SelectedItem.ToString().Split('|')))[1]).Trim();
         if (cv != null)
         {
             cv.close();
         }
         cv        = svr.getApplication(essApp).getCube(essDB).openCubeView("JDH_CubeView");
         connected = true;
         this.Dispose();
     }
     catch (Exception ex)
     {
         MessageBox.Show("Error connecting: " + ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }