Extentrix Developer Network-Extentrix Web Services for Citrix Presentation Server
Extentrix Web Services Consumer using ASP.NET (AutocadViewer)
Introduction
Requirements
Application Source Code
How to Call Extentrix Web Services
Application Edition 3.5 API using ASP.Net
Introduction
This sample shows how to invoke Extentrix Web Services for Citrix Presentation Server APIs using ASP.Net. It invokes one of the APIs (launchApplicationWithParameter).
Requirements
- To run this sample, you need Visual Web Developer Express Edition, VS with IIS or VS2005, Framework version 2.0
- Any web browser
- Security Requirements:
Enable Initialize and script ActiveX controls option. For Internet Explorer do the following:
A) From Internet Explorer, go to Tools >> Internet Options.
.png)
Figure 1
B) Select Security tab, go to Custom level.
.jpg)
Figure 2
C) Enable "Initialize and script ActiveX controls not marked as safe for scripting" option.

Figure 3
This is not an ASP.Net tutorial, so it will only briefly describe what the code does. We assumed the person who is reading this has a good knowledge of it.
Application Source Code
There are two main packages:
- Default.aspx.
This page is the main page in this sample; it contains a link to the MyDesign file in a .dwf format. It saves the ICA content into the client’s machine and runs it using ICAWEB client ((com.citrix.JICA) applet) that exists on the citrix presentation server java CodeBase URL. Browser.aspx.
This is the second page in this sample. It launches the published AutoCAD viewer and open MyDesign file -in .dwf format- in browser.
How to Call Extentrix Web Services
Application Edition 3.5 API using ASP.Net
- You need to add a web reference to Extentrix Web Services for Citrix Presentation Server by following these steps:
- You need to add the following Using statements to invoke the web services:
- You need to create an object from the created web service reference.ExtentrixServiceCitrixPS proxy = new
ExtentrixServiceCitrixPS(); - Create Credential object, and set its members.WindowsCredentials credentials = new WindowsCredentials(); credentials.Password = "demo"; credentials.UserName = "citrixdesktop"; credentials.Domain = "testdrive"; credentials.PasswordEncryptionMethod = 0; credentials.DomainType = 0;
- Invoke the web service.
string icaContent = proxy.LaunchApplicationWithParameter(application, filename, credentials, clientname, clientIP);
a. Right click your project node and select Add Web Reference as in Figure 4.
.jpg)
Figure 4
b. A window named “Add Web Reference” will appear. Add the URL of your Extentrix Web Services Application Edition in URL field and click GO. You can use our published web service URL for test purposes: http://www.extentrix.com/webservices/3.5.0/ExtentrixServiceCitrixPS.asmx.
.png)
Figure 5
c. In Web reference name field, give a suitable name for the web reference and click Add Reference.