Creating an ApplinX Web Application


Creating an ApplinX for JSP Web Application using the Software AG Designer (recommended)

The following is based on the released Eclipse version. Additional information can be found on Eclipse website and WTP (web tool platform) site.

Start of instruction setTo create a new Dynamic Web project

  1. In the Eclipse workspace, select File > New > Project to create a new project.

  2. Select Web > Dynamic Web Project.

  3. Click Next to create a new web project. The New Dynamic Web Project dialog box is displayed.

    graphics/Dynamic.png

  4. Enter a name for the project.

  5. In the Target Runtime field, select the Tomcat installation: click New... and select the server to be used: Either J2EE Preview (recommended) or Tomcat v5.5.

    Important:
    The Restart function in the J2EE Preview server does not work properly. Instead of using the Restart function, stop and the start the server. In addition, editing files only works after stopping and starting the server.

    graphics/serverruntime.png

  6. Click Next.

    graphics/serverinstallation.png

  7. Browse and select the Tomcat installation.

    Note:
    Currently the ApplinX internal Tomcat cannot be used to create a web application and when selecting to use Tomcat, you are required to install an additional Tomcat 5.5 version.

  8. Select a JRE or click Installed JREs... to add a new JRE. The Preferences dialog box is displayed.

    graphics/WAJSP3.png

  9. Define the Runtime Environment (JRE) for the server: JSP server requires a full JDK and not only the JRE bundle. If you need to add a new JRE, click the Add... button.

    graphics/WAJSP4.png

  10. Assign a name to the new JRE.

  11. Enter the JRE home directory (when necessary, click Browse... to locate the file).

  12. Add VM arguments when required.

  13. Click OK to return to the New Server Runtime dialog box. Select the newly created JRE. Click OK.

  14. Click Finish. The New Dynamic Web Project dialog box is displayed.

    You have completed the configuration of the flexible project, the server (Tomcat) and the JDK.

  15. Change the configuration to Custom and click Modify.

    Select ApplinX Framework. Ensure that the Dynamic Web Module and Java check boxes are selected. Click OK.

    graphics/WAJSP5.png

  16. Click Next.

  17. Click Next.

  18. Select ApplinX installation from which to create the web project and select the application type.

    graphics/WAJSP6.png

  19. Click Next.

    graphics/WAJSP6a.png

    Select the template to use in your application.

  20. Click Finish.

    You have completed the creation of a standard WAR file (Java Web Archive).

  21. Ensure that in the Project menu, Build Automatically is selected.

    To run the project, right-click on the project's folder in the Project Explorer view and select Run As > Run on Server....

    The first time you run a project you are required to select a default server:

    Select the server you configured.

    Select the Always use this server when running this project check box. The next time you run the application, this dialog box will not be displayed. The server you selected will automatically be used.

    Click Finish to continue. A browser window will be opened.

    Note:
    The browser type can be configured under Windows > Preferences > General > Web Browser. It is recommended to configure it to Default system web browser.

Using the Javadoc as a reference within the code

When using the Javadoc you will have:

  • Online usage of the Eclipse Javadoc for ApplinX API.

  • Suggested argument names for the ApplinX API, instead of arg0, arg1, etc.

Start of instruction setTo use Javadoc capabilities when developing your project

  1. Right-click on the project node and select Build Path > Configure Build Path.... The Properties dialog box is displayed.

  2. In the Libraries tab, expand the gxframework.jar node, click on Javadoc location and then click on the Edit... button to determine the location of the Javadoc.

  3. You can either enter the URL http://localhost:2380/applinx-help or browse and select the Javadoc location path <Software AG installation> > ApplinX > Help > API. Then click OK.

  4. Click OK to close the Properties dialog box.

Creating an ApplinX for JSP Web Application using JDK and Tomcat (no IDE)

Note:
This is not available when working with a SOA license.

Start of instruction setTo create a new JSP application without any IDE and with JDK

Refer to ApplinX for JSP Web Application in Software Requirements.

  1. During the installation process, choose the option ApplinX Framework for JSP.

  2. In the ApplinX Explorer, right-click on the relevant application and select Web Application Manager.... The Web Application Manager wizard is displayed.

    graphics/WebAppMangr1.png

  3. Ensure that Create a new Web application (for IIS or Tomcat) is selected. Click Next. The Create a New Web Application screen is displayed.

    graphics/WebAppMangr2JS.png

  4. Ensure that JSP is selected. Select the application type: New application to create a basic ApplinX web application with a web look and feel or Emulation template to create an ApplinX web application with a host look and feel.

  5. Click Next. The Select Template screen is displayed.

    graphics/WebAppMangr3.png

    Select a template from the list on the left.

  6. Click Next. The Create a New JSP Web Application screen is displayed.

    graphics/WebAppMangr4JS.png

    Enter a name for the web application. By default this is the name of the ApplinX application that you selected. Browse and select the folder where Tomcat is installed. Select the location of the JDK installation.

    When you wish to use the ApplinX internal Tomcat, select the corresponding check box.

  7. Click Next. The Wizard Summary screen is displayed.

  8. Select whether to launch the browser when the process is completed.

  9. Select whether to restart Tomcat. This is only relevant when Tomcat is activated from a batch file. The Framework Manager does not support restarting Tomcat when Tomcat runs as a Windows Service (in this case, you need to manually restart Tomcat).

  10. Click Finish. A message will be displayed indicating whether the process succeeded or failed.

Note:
Any change in the Java file requires recompilation of your new application. Changes in JSP files do not require recompilation. Furthermore, Tomcat requires reloading: http://localhost:8080/manager/reload?path=/<YOUR_APP_NAME>.

Creating an ApplinX .NET Web Application using Visual Studio 2008

Start of instruction setTo create a new ApplinX web application using Visual Studio 2008

  1. Install J# 2.0 redistributable package Second edition.

  2. Install Microsoft Visual Studio 2008 on your computer (install Visual Studio before installing ApplinX so that when installing ApplinX, the ApplinX web application templates will be added to the available Visual Studio New Web Sites).

  3. Open Visual Studio 2008.

  4. In the File menu, select New and then Web Site... to create a new web site. The New Web Site dialog box is displayed.

  5. Select the relevant ApplinX web application type (Visual C# or Visual Basic).

  6. Determine whether you would like to upgrade to .NET framework 3.5 or continue working with .NET framework 2.0 (both options are acceptable).

  7. Define that index.aspx will be the start page (right-click on index.aspx and select Set as Start Page).

  8. Run the web site.

  9. In the Framework Configuration Editor, define the connection parameters as follows:

    1. Click on the Framework Configuration link. The Configuration Editor will be displayed.

    2. In the Session node, enter the application name. By default, the application name is "InstantDemo". In the Session node, it is possible to edit and configure additional connection and project properties.

    3. Click Save to save your changes.

    4. Click Close to return to the web application.

Creating an ApplinX .NET Web Application using Visual Studio 2010

Start of instruction setTo create a new ApplinX web application using Visual Studio 2010

  1. Install J# 2.0 redistributable package.

  2. Install .NET Framework 3.5 SP1.

  3. Install Microsoft Visual Studio 2010 on your computer (install Visual Studio before installing ApplinX so that when installing ApplinX, the ApplinX web application templates will be added to the available Visual Studio New Web Sites).

  4. Open Visual Studio 2010.

  5. In the File menu, select New and then Web Site... to create a new web site. The New Web Site dialog box is displayed.

  6. Select to work either with .NET Framework 2.0 or 4.0.

  7. Select the relevant ApplinX web application type (Visual C# or Visual Basic).

  8. Define that index.aspx will be the start page (right-click on index.aspx and select Set as Start Page).

  9. Run the web site

  10. In the Framework Configuration Editor, define the connection parameters as follows:

    1. Click on the Framework Configuration link. The Configuration Editor will be displayed.

    2. In the Session node, enter the application name. By default, the application name is "InstantDemo". In the Session node, it is possible to edit and configure additional connection and project properties.

    3. Click Save to save your changes.

    4. Click Close to return to the web application.

Creating an ApplinX .NET Web Application using .NET (no IDE)

Note:
This is not available when working with a SOA license.

Start of instruction setTo create a new ASP.NET application without Visual Studio .NET with .NET SDK

  1. During ApplinX installation, select the ApplinX ASP.NET Web Framework C#/VB .NET option.

  2. In the ApplinX Explorer, right-click on the relevant application and select Web Application Manager.... The Web Application Manager wizard is displayed.

    graphics/WebAppMangr1.png

  3. Ensure that Create a new Web application (for IIS or Tomcat) is selected. Click Next. The Create a New Web Application screen is displayed.

    graphics/WebAppMangr2NET.png

  4. Ensure that C# 2.0 or VB 2.0 is selected. Select the application type: New application to create a basic ApplinX web application with a web look and feel or Emulation template to create an ApplinX web application with a host look and feel.

    Note:
    If you wish to create a new web application based on .NET 4.0, you need to use Visual Studio 2010 (refer to Creating an ApplinX .NET Web Application using Visual Studio 2010).

  5. Click Next. The Select Template screen is displayed.

    graphics/WebAppMangr3.png

    Select a template from the list on the left. Click Next.

  6. The Create a New .NET Web Application screen is displayed.

    graphics/WebAppMangr4NET.png

  7. Enter a name for the web application. By default, this is the name of the ApplinX application that you selected. Browse and select the destination folder.

  8. Click Next. The Wizard Summary screen is displayed.

  9. Select whether to launch the browser when the process is completed.

  10. Click Finish. A message will be displayed indicating whether the process succeeded or failed.

    Note:
    When using the Application Manager on IIS 7.5 or 8.0, you need to convert your application from a virtual directory to a web application (in the IIS manager, right-click on your application and select Convert to Application).

Upgrading an ApplinX .NET Web Application from Visual Studio 2003 to 2005

Start of instruction setTo upgrade a project from Visual Studio 2003 to Visual Studio 2005

  1. In Visual Studio 2005, open the web application by clicking File > Open > WebSite... and selecting the web application.

  2. The Visual Studio Conversion Wizard is displayed. Click Next.

  3. Determine whether you would like to create a backup before converting.

  4. Click Finish.

  5. The conversion process is run. Once completed, errors are displayed in the conversion log. When necessary, make the required changes to correct these errors (error lines relating to the project file do not need to be dealt with, as from this point, you are working with a web site and not a web project). For example, an error "Unable to move file" should be corrected by manually moving the file.

  6. Build the web site. If errors are displayed, check what these errors are and make the necessary changes.

  7. Close the web site (File > Close > Solution).

  8. In ApplinX Designer, upgrade your web application using the ApplinX Web Application Manager (refer to Upgrading a .NET Web Application in Web Application Development.

  9. Reopen the web application in Visual Studio 2005 (File > Open > WebSite... and select the web application).

  10. Build the web site. Correct errors.

  11. Define that index.aspx will be the start page (right-click on index.aspx and select Set as Start Page).

  12. You can run the web site to ensure that it performs as expected.

Upgrading an ApplinX .NET Web Application from Visual Studio 2003 to 2008

Start of instruction setTo upgrade a project from Visual Studio 2003 to Visual Studio 2008

Ensure that you have J# 2.0 redistributable package installed.

  1. In Visual Studio 2008, open the web application by clicking File > Open > WebSite... and selecting the web application.

  2. The Visual Studio Conversion Wizard is displayed. Click Next.

  3. Determine whether you would like to create a backup before converting. Click Next.

  4. Determine whether you would like to work with .NET 2.0 or .NET 3.5.

  5. Click Finish.

  6. The conversion process is run. Once completed, errors are displayed in the conversion log. When necessary, make the required changes to correct these errors (error lines relating to the project file do not need to be dealt with, as from this point, you are working with a web site and not a web project). For example, an error "Unable to move file" should be corrected by manually moving the file.

  7. Build the web site. If errors are displayed, check what these errors are and make the necessary changes.

  8. Close the web site (File > Close > Solution).

  9. In ApplinX Designer, upgrade your web application using the ApplinX Web Application Manager (refer to Upgrading a .NET Web Application in Web Application Development.

  10. Reopen the web application in Visual Studio 2008 (File > Open > WebSite... and select the web application).

  11. Build the web site. Correct errors.

  12. Define that index.aspx will be the start page (right-click on index.aspx and select Set as Start Page).

  13. You can run the web site to ensure that it performs as expected.

Upgrading an ApplinX .NET Web Application to Visual Studio 2010

Start of instruction setTo upgrade a project to Visual Studio 2010

Ensure that you have J# 2.0 redistributable package Second edition installed.

  1. When upgrading to Visual Studio 2010 from Visual Studio 2003, you need to first perform the upgrade task above: either Upgrading an ApplinX Web Application from Visual Studio 2003 to 2005 or Upgrading an ApplinX Web Application from Visual Studio 2003 to 2008.

  2. In Visual Studio 2010, open the web application by clicking File > Open > WebSite... and selecting the web application.

  3. Determine whether you would like to work with .NET 2.0 or .NET 4.0.

  4. In ApplinX Designer, upgrade your web application using the ApplinX Web Application Manager (refer to Upgrading a .NET Web Application in Web Application Development.

  5. Define that index.aspx will be the start page (right-click on index.aspx and select Set as Start Page).

  6. You can run the web site to ensure that it performs as expected.