Highlighted
Absent Member.
Absent Member.
1685 views

Deployment web site using RMCobol dll

Jump to solution

[Migrated content. Thread originally posted on 26 March 2012]

Hello, I have a solution running ok with website Cobol and RmCobol dll, I want to know How to deploy the application in order to install in IIS, this IIS is in a computer without visual studio and How to do for install rmfiles in the server and How to install RM files in other computer in the web in order to access them.

0 Likes
1 Solution

Accepted Solutions
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: Deployment web site using RMCobol dll

Jump to solution

The following are instructions on how to deploy a Visual COBOL ASP.NET web site onto a production server running Windows 7 and IIS 7.

This includes web sites that call native .dlls that are using the ACU/RM file handler:


Deploying COBOL ASP.NET Web Services and Web Sites developed with Visual COBOL under IIS

Because the COBOL 2010 Runtime product does not include the COBOL compiler the following steps must be used when deploying the web site to a Production server.

In this example the web site is in folder C:\testwebsite and the name of the web site is also testwebsite.

1. On the target computer, install the COBOL 2010 Runtime product.
2. Open the Micro Focus License Manager and install the authorization code for the COBOL 2010 Runtime product.
3. If you are using any native COBOL .dlls in your web site ensure that they are being linked with the dynamic option by checking the Properties->COBOL Link tab for the native projects. If they are linked as shared then you will have to add the COBOL 2010 Runtime\bin folder to the PATH on the target computer.
4. Precompile the web site:
On the development computer open the web site in the Visual Studio IDE and select Build->Publish Web site from the IDE menu.
Select a location to place the precompiled site such as C:\PrecompiledWeb\testwebsite and click OK to publish the site.
5. Copy the subfolder containing the precompiled web site to your target computer.
In this example, I copied the testwebsite subfolder of C:\PrecompiledWeb to the production computer as C:\testwebsite.
6. On the target computer start Windows Explorer and navigate to the C:\testwebsite folder, right click on your files with the .aspx extension (Web Page) and select edit.

You will see something similar to the following line:
<%@ page language="COBOL" autoeventwireup="true" inherits="_Default, App_Web_zcawdwq5" %>

Remove the Language="COBOL" option so it looks like:

<%@ page autoeventwireup="true" inherits="_Default, App_Web_zcawdwq5" %>

and Save it.

Do this for each of your web pages.

7. Right click on web.config in the same folder and select Edit.

You will see the following section:
<system.web>
<compilation batch="false" debug="true" targetFramework="4.0"/>
</system.web>

Change the debug="true" option to "false" and remove the targetFramework so that it looks like:
<system.web>
<compilation batch="false" debug="false" />
</system.web>

In the same file you will see the following section:

<system.codedom>
<compilers>
<compiler language="COBOL" extension=".cbl" compilerOptions="sourceformat(variable) warnings(2)" type="MicroFocus.COBOL.CodeDom.COBOLCodeProvider, MicroFocus.COBOL.CodeDom, Version=4.0.0.0, Culture=neutral, PublicKeyToken=0412c5e0b2aaa8f0"/>
</compilers>
</system.codedom>

comment this section out by adding the following two comment lines:
<!--
<system.codedom>
<compilers>
<compiler language="COBOL" extension=".cbl" compilerOptions="sourceformat(variable) warnings(2)" type="MicroFocus.COBOL.CodeDom.COBOLCodeProvider, MicroFocus.COBOL.CodeDom, Version=4.0.0.0, Culture=neutral, PublicKeyToken=0412c5e0b2aaa8f0"/>
</compilers>
</system.codedom>
-->

Save the changes and exit.

8. If you have any native .dlls that the application is calling you need to add their location to the system PATH environment variable.
You should copy the native .dlls into the bin folder of the web site, in this example c:\testwebsite\bin and then add this folder to
the PATH using Control Panel-->System-->Advanced-->Environment variables.
If you are using any other environment variables such as A_CONFIG or COBCONFIG you should also set them to point to the location of their relevant files.

9. After making these changes reboot the target computer.
10. When the system restarts, open up IIS Manager under Administrative Tools.
Navigate under Connections to the branch for Default Web Site and Right click and select Add Virtual Directory.
Alias should contain the name of your web site and Physical Path should be the top level folder, e.g. C:\testwebsite.
Save this.

11. In IIS, right click on your new Alias and select Convert to Application. Click OK.

12. If you are deploying your ASP.NET Web Site or Web Service to a 64-bit OS then you have the option of doing the following:

- In IIS Manager click on the branch for Application Pools.
- In the list of Application Pools select DefaultAppPool and under Actions select Advanced Settings.
- Set the option Enable 32-Bit Applications to True.
- Ensure that the setting for .NET Framework version set to the coirrect version that you are running most likely 4.0.
- Click OK to save.

Test the web site by starting Internet Explorer and entering http://localhost/testwebsite

Your Web Service or Web Site should now run correctly.


View solution in original post

0 Likes
1 Reply
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: Deployment web site using RMCobol dll

Jump to solution

The following are instructions on how to deploy a Visual COBOL ASP.NET web site onto a production server running Windows 7 and IIS 7.

This includes web sites that call native .dlls that are using the ACU/RM file handler:


Deploying COBOL ASP.NET Web Services and Web Sites developed with Visual COBOL under IIS

Because the COBOL 2010 Runtime product does not include the COBOL compiler the following steps must be used when deploying the web site to a Production server.

In this example the web site is in folder C:\testwebsite and the name of the web site is also testwebsite.

1. On the target computer, install the COBOL 2010 Runtime product.
2. Open the Micro Focus License Manager and install the authorization code for the COBOL 2010 Runtime product.
3. If you are using any native COBOL .dlls in your web site ensure that they are being linked with the dynamic option by checking the Properties->COBOL Link tab for the native projects. If they are linked as shared then you will have to add the COBOL 2010 Runtime\bin folder to the PATH on the target computer.
4. Precompile the web site:
On the development computer open the web site in the Visual Studio IDE and select Build->Publish Web site from the IDE menu.
Select a location to place the precompiled site such as C:\PrecompiledWeb\testwebsite and click OK to publish the site.
5. Copy the subfolder containing the precompiled web site to your target computer.
In this example, I copied the testwebsite subfolder of C:\PrecompiledWeb to the production computer as C:\testwebsite.
6. On the target computer start Windows Explorer and navigate to the C:\testwebsite folder, right click on your files with the .aspx extension (Web Page) and select edit.

You will see something similar to the following line:
<%@ page language="COBOL" autoeventwireup="true" inherits="_Default, App_Web_zcawdwq5" %>

Remove the Language="COBOL" option so it looks like:

<%@ page autoeventwireup="true" inherits="_Default, App_Web_zcawdwq5" %>

and Save it.

Do this for each of your web pages.

7. Right click on web.config in the same folder and select Edit.

You will see the following section:
<system.web>
<compilation batch="false" debug="true" targetFramework="4.0"/>
</system.web>

Change the debug="true" option to "false" and remove the targetFramework so that it looks like:
<system.web>
<compilation batch="false" debug="false" />
</system.web>

In the same file you will see the following section:

<system.codedom>
<compilers>
<compiler language="COBOL" extension=".cbl" compilerOptions="sourceformat(variable) warnings(2)" type="MicroFocus.COBOL.CodeDom.COBOLCodeProvider, MicroFocus.COBOL.CodeDom, Version=4.0.0.0, Culture=neutral, PublicKeyToken=0412c5e0b2aaa8f0"/>
</compilers>
</system.codedom>

comment this section out by adding the following two comment lines:
<!--
<system.codedom>
<compilers>
<compiler language="COBOL" extension=".cbl" compilerOptions="sourceformat(variable) warnings(2)" type="MicroFocus.COBOL.CodeDom.COBOLCodeProvider, MicroFocus.COBOL.CodeDom, Version=4.0.0.0, Culture=neutral, PublicKeyToken=0412c5e0b2aaa8f0"/>
</compilers>
</system.codedom>
-->

Save the changes and exit.

8. If you have any native .dlls that the application is calling you need to add their location to the system PATH environment variable.
You should copy the native .dlls into the bin folder of the web site, in this example c:\testwebsite\bin and then add this folder to
the PATH using Control Panel-->System-->Advanced-->Environment variables.
If you are using any other environment variables such as A_CONFIG or COBCONFIG you should also set them to point to the location of their relevant files.

9. After making these changes reboot the target computer.
10. When the system restarts, open up IIS Manager under Administrative Tools.
Navigate under Connections to the branch for Default Web Site and Right click and select Add Virtual Directory.
Alias should contain the name of your web site and Physical Path should be the top level folder, e.g. C:\testwebsite.
Save this.

11. In IIS, right click on your new Alias and select Convert to Application. Click OK.

12. If you are deploying your ASP.NET Web Site or Web Service to a 64-bit OS then you have the option of doing the following:

- In IIS Manager click on the branch for Application Pools.
- In the list of Application Pools select DefaultAppPool and under Actions select Advanced Settings.
- Set the option Enable 32-Bit Applications to True.
- Ensure that the setting for .NET Framework version set to the coirrect version that you are running most likely 4.0.
- Click OK to save.

Test the web site by starting Internet Explorer and entering http://localhost/testwebsite

Your Web Service or Web Site should now run correctly.


View solution in original post

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.