Use the search and browse feature to view Kepware's repository of more than 500 Knowledge Base articles. Narrow your results or type your query into the search field below.

Search Solutions Results By: View All Solutions

Kepware Knowledge Base: Solution


Can ClientAce Be Used with Visual Studio 2010 and the .Net 4.0 Framework?


Last Update: 11/12/2018

Yes, it can. ClientAce version 4.0 binaries target the .NET 4.0 or 4.5 Framework, and can be used in any Visual Studio 2010 or higher project. Because ClientAce version 3.5 binaries target the .Net 3.5 Framework, the easiest way to use it in Visual Studio 2010 is to set the target .Net Framework to .Net 3.5.

Because ClientAce version 3.5 may need to be used in projects whose components require .Net 4.0 support, it can be configured to use .Net 4.0 for all components except the ClientAce DA Junction. For more information, refer to the instructions below.

  1. To start, add an Application Configuration file by right-clicking on the project in Solution Explorer and selecting Add | New Item.
  2. Locate the Application Configuration file beneath General, and then add the following code:<?xml version="1.0" encoding="utf-8" ?> <configuration> <startup useLegacyV2RuntimeActivationPolicy="true"> <supportedRuntime version="v2.0"/> <supportedRuntime version="v4.0"/> </startup> </configuration>
  3. Next, set the target .Net Framework to .Net Framework 4 Client Profile.
    • In C#, the target is located in Project Properties | Application.
    • In VB.Net, the target is located in Project Properties | Compile | Advanced Compile Options.
  4. Once finished, either compile the project or run it in Debug Mode.

    Note: The project should run without any problems. Users that attempt to utilize the ClientAce DA Junction in the project will receive the following error at compilation: "Type 'Kepware.ClientAce.DA_Junction.ClientAceDA_Junction' is not defined."

See Also: C# Example Code and VB.Net Example Code.

Related Products
ClientAce