How to: Define Operation and Parameter Types for ASP.NET Web Services
In Application Designer and System Designer, you can define the operation and parameter types for a Web service provider endpoint on an ASP.NET application. When you define Web service operations and parameters in the Web Service Details window, you can either select a type, reference a type defined in another project, or reference a type that you define later. After you implement the application, you can also define the type in code or by using Class Designer.
Note
You must first implement the application before you can define an operation or parameter type. If you reference a type that is defined in another project, you must add references to those projects after you implement the application. For more information, see How to: Implement Applications on Application Diagrams and How to: Add and Remove References in Visual Studio (C#).
For more information, see the following topics:
To define an operation or parameter type
On the diagram, select a Web service provider endpoint on an ASP.NET application.
On the Diagram menu, choose Define Operations.
Tip
You can also right-click the endpoint to choose Define Operations.
The Web Service Details window appears.
In the Web Service Details window, right-click the operation or parameter row with the type you want to define and choose Define '<typename>' in the Current Project.
In Solution Explorer, a class file for the type is added to the associated application project. You can now choose to use Class Designer to visually define the type on a class diagram.
When you are prompted to open Class Designer, choose one of the following:
Yes to add a class diagram (.cd) file to the project and open Class Designer.
No to decline adding a class diagram.
Instead, you can define the type in the class file or add a reference to a class library that defines the type.
Tip
You can always use Class Designer at a later time to define the type. For more information, see How to: Edit Operation and Parameter Types for ASP.NET Web Services and Designing and Viewing Classes and Types.
See Also
Tasks
How to: Delete Operations and Parameters from ASP.NET Web Services
Reference
Keyboard Shortcuts for the Web Service Details Window