Back to Devexpress

Xcopy Deployment of a Windows Forms Application

expressappframework-113232-deployment-winforms-xcopy-deployment-of-a-windows-forms-application.md

latest4.2 KB
Original Source

Xcopy Deployment of a Windows Forms Application

  • Feb 21, 2026
  • 5 minutes to read

In this lesson, you will learn how to deploy a Windows Forms XAF application using the Xcopy Deployment method. This method is named after the xcopy command-line utility, which copies files from one location to another. With this method, you copy the application files from the Developer Workstation to a location accessible to end-users.
Instead of the xcopy utility, you can use Windows Explorer or another file manager to copy files. However, in certain cases, the command-line utility may be more convenient than graphical user interface (GUI) tools. To learn more about the xcopy command capabilities, refer to the xcopy document.

Perform the following steps at the Developer Workstation to prepare the Windows Forms application for Xcopy Deployment.

  • Open the MySolution solution in Visual Studio. In the Solution Explorer, expand the MySolution.Win\References folder. Select assemblies whose names start with “DevExpress”. If you use Entity Framework, third-party controls or modules, select their assemblies as well. In the Properties window, set the CopyLocal property to True.

  • Change the Active Solution Configuration from Debug to Release.

  • Build and run the Windows Forms application.

  • Check to make sure that the application performs correctly and close it.

  • Ensure that the MySolution\MySolution.Win\bin\Release folder contains application files.

Now, the Windows Forms application is ready for Xcopy Deployment.

Perform the following steps at an End-User Workstation or at a Terminal Server.

  • Ensure that an appropriate version of .NET is installed.

  • Create an application folder. For instance, it can be C:\Program Files\MySolution. Copy the MySolution\MySolution.Win\Bin\Release folder contents from the Developer Workstation to the newly created directory via the network or using removable media.

  • If the application is localized, and pre-built satellite assemblies are used in it, do the following.

  • Create a desktop shortcut to the C:\Program Files\MySolution\MySolution.Win.exe file. Name it MySolution.

  • Run the application by double-clicking the MySolution.Win.exe file or its shortcut. If the following error message stating that an assembly is missing is displayed, then the reported assembly was not copied to the Release folder from the Developer Workstation Global Assembly Cache (GAC).

  • Finally, the application will display the following message.

Note

If you experience problems performing any steps of this lesson, refer to the Deployment Troubleshooting Guide lesson.

Copy the C:\Program Files\MySolution folder and the MySolution desktop shortcut to each of the remaining End-User Workstations, if necessary. If you are deploying a Windows Forms application to the Terminal Server, follow the steps from the Connect Clients to the Terminal Server lesson.

Now your application needs a connection to a database to run properly. Proceed to the Set Up the Database Connection lesson to learn how to do it. To familiarize yourself with alternative deployment methods, take one of the following lessons.

See Also

Redistribution and Deployment

Deployment Troubleshooting Guide