In any of the projects in which the assembles are not located, Update project->properties->Progress OpenEdge->Assemblies. Uncheck the checkbox entitled "Use Default". Select the project where the assemblies are located. The assemblies location shows up as platform:/resource/<assembly name>.
Copy the file toolbox.xml from the project where the assemblies reside to the top level directory of the project that needs access to the .NET controls.
In the project where the assemblies reside, add an additional statrup parameter, as follows: -assemblies <path to the project where the assemblies reside>.
In the project where the assemblies reside, add a file entitled assemblies.config. This points to the subdirectories where the assemblies reside.
The format of assemblies.config is as follows:
<?xml version="1.0" encoding="utf-8" ?> <configuration> <runtime> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <probing privatePath="myControls\winforms" /> </assemblyBinding> </runtime> </configuration>
The value assigned to privatePath is a semi-colon separated string containing subdirectories where assemblies reside. The string can contain up to 9 subdirectory object within the string. The assemblies can be placed in any of the subdirectories listed in the file assemblies.config. The subdirectories must be relative to the location of the assemblies.xml file. This is generally in the main directory of a project.
In addition, it is important to be mindful of run/debug configuration settings, on the Startup tab. This is in reference to the "Use project settings checkbox and the Assemblies directory textbox. These are contained in the box entitled Common Language Runtime (.NET). According to the documentation describing the "Use project setting" checkbox and the Assembies directory textbox:
Use project settings: If checked, causes the configuration to use the same settings as the project (specified on the Main tab) for the assemblies directory and for loading of the Common Language Runtime.
Assemblies directory: Optionally specifies the directory (full path or path relative to the working directory) containing the assemblies.xml file and any third-party .NET assemblies. If this field is blank, the working directory for the specified project is assumed. This field is disabled if Use project settings is checked.
Please be mindful of the last line of the Assemblies directory section: This field is disabled if Use project settings is checked. If the Use project settings checkbox is checked, the Assemblies directory textbox contents is disabled (ignored). In that case the directory dlc\bin is the only directory searched for assemblies (along with subdirectories in the privatepath in the assemblies.config file in dlc\bin). If Use project settings is checked, a -assemblies startup parameter must be used assuming the project's assemblies are not in dlc\bin or its subdirectories). The value assigned to -assemblies must be the directory where the assemblies.xml and (optionally) where assemblies.config are located. |