Ejemplo n.º 1
0
 /// <remarks/>
 public void ActivateViewerAsync(ActivateViewerRequest request, object userState)
 {
     if ((this.ActivateViewerOperationCompleted == null))
     {
         this.ActivateViewerOperationCompleted = new System.Threading.SendOrPostCallback(this.OnActivateViewerOperationCompleted);
     }
     this.InvokeAsync("ActivateViewer", new object[] {
         request
     }, this.ActivateViewerOperationCompleted, userState);
 }
Ejemplo n.º 2
0
 /// <remarks/>
 public void ActivateViewerAsync(ActivateViewerRequest request, object userState) {
     if ((this.ActivateViewerOperationCompleted == null)) {
         this.ActivateViewerOperationCompleted = new System.Threading.SendOrPostCallback(this.OnActivateViewerOperationCompleted);
     }
     this.InvokeAsync("ActivateViewer", new object[] {
                 request}, this.ActivateViewerOperationCompleted, userState);
 }
Ejemplo n.º 3
0
 /// <remarks/>
 public void ActivateViewerAsync(ActivateViewerRequest request) {
     this.ActivateViewerAsync(request, null);
 }
Ejemplo n.º 4
0
 /// <remarks/>
 public void ActivateViewerAsync(ActivateViewerRequest request)
 {
     this.ActivateViewerAsync(request, null);
 }
Ejemplo n.º 5
0
 public void ActivateViewer([System.Xml.Serialization.XmlElementAttribute(IsNullable = true)] ActivateViewerRequest request)
 {
     this.Invoke("ActivateViewer", new object[] {
         request
     });
 }
Ejemplo n.º 6
0
		private void OnActivateViewer(object sender, EventArgs e)
		{
			StudyItem study = GetSelectedStudy();
			if (study == null)
			{
				MessageBox.Show("Select a single study item in the list.");
				return;
			}

			Guid? viewerId = GetSelectedViewer();
			if (viewerId == null)
			{
				MessageBox.Show("An active viewer must be selected.");
				return;
			}

			using (AutomationClient client = new AutomationClient())
			{
				try
				{
					ActivateViewerRequest request = new ActivateViewerRequest();
					request.Viewer = new Viewer();
					request.Viewer.Identifier = GetIdentifier(viewerId.Value);
					client.ActivateViewer(request);
				}
				catch (Exception ex)
				{
					study.RemoveViewer(viewerId.Value);
					MessageBox.Show(ex.Message);
				}
			}
		}