Udostępnij za pośrednictwem


How to: Copy Between Solutions or Instances of Visual Studio

In Distributed System Designers, you can copy items between diagrams of the same type. These diagrams can be in separate instances of Visual Studio.

Note

You cannot copy items between deployment diagrams.

For example, you can copy applications, endpoints, and connections from one application diagram to another in a different distributed system solution.

Tip

To define applications, logical servers, zones, or endpoints using already configured ones, see How to: Create Custom Prototypes from Configured Applications and Endpoints and How to: Create Custom Prototypes from Configured Zones and Logical Servers. To copy and paste items on diagrams as images in other documents, see How to: Export Distributed System Diagrams to Other Documents.

To copy items between solutions or instances of Visual Studio

  1. In the source instance of Visual Studio, select one or more items you want to copy from the diagram.

  2. On the Edit menu, choose Copy.

  3. In the destination instance of Visual Studio, choose Paste from the Edit menu to paste the items on the diagram.

    Tip

    You can also right-click the selected objects to choose Copy and then right-click the destination diagram to choose Paste.

    The copied items are pasted on the destination diagram.

When you copy an implemented application between application diagrams in different solutions or instances of Visual Studio, an unimplemented copy of the application is pasted on the destination diagram. When you implement the application, Visual Studio generates the associated project files that are scoped to the destination solution.

Tip

If you want to reference the same application from the source solution, add the project or Web site to the destination solution, which reverse-engineers the application on the application diagram in the destination solution. For more information, see How to: Reverse-Engineer Projects in Existing Solutions and How to: Implement Applications on Application Diagrams.

When you copy a Web service provider endpoint that was created from a WSDL or DISCO file on the application diagram, the copy includes any operation signatures that were added to that endpoint. Typically, once an ASP.NET application with such an endpoint is implemented, the application project includes class files containing the definitions of any types referenced by the operations and parameters specified by those signatures. However, for ASP.NET applications with copies of such endpoints, the corresponding application projects will not include these class files for referenced types. For more information, see Overview of ASP.NET Applications on Application Diagrams.

When you copy a member of a system between system diagrams, that member appears on the destination diagram with a red dashed outline if the definition for that member does not exist in the destination solution. To resolve this condition, see Troubleshooting System Diagrams.

See Also

Other Resources

Common Tasks Across Distributed System Designers