ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / Developing in Java
  • Overview
  • Generating a Java application with WINDEV
  • Creating a Java project
  • Creating the project
  • Modifying the type of generation for the project
  • Characteristics of a Java project
  • RAD available in Java
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Overview

Generating a Java application with WINDEV

WINDEV allows you to generate a Java application without even knowing the Java language. The method for developing the application is identical to the method for developing any other WINDEV application.
When the WINDEV project is compiled, the windows and the WLanguage functions are automatically converted into Java.
Remark: We advise you create a new WINDEV project to develop a Java application rather than transform a WINDEV application into Java.
Creating a Java project

Creating the project

A Java project is created like any other WINDEV project.
To create a project:
  • Click in the quick access buttons.
  • The new element window appears: click "Project".
  • The project creation wizard starts.
In one of the first steps of the wizard, you can choose the type of project that will be generated. To do so, select "Java archive" and continue.
Once your project is created, you develop in WLanguage like for any other WINDEV application.
Remark: The number of WLanguage functions that can be used in a Java project is limited in this version. This number of functions will increase in forthcoming versions. For more details, see Functions available in Java.

Modifying the type of generation for the project

By default, a WINDEV project for Java corresponds to a specific project configuration. The type of generation for the project can be modified at any time. Simply create a new project configuration.
To manage the project configurations, go to the "Project" tab, "Project configuration" group and click "Manage configurations". For more details, see Project configurations.

Characteristics of a Java project

Once the project has been configured as a Java project, all the tools available in WINDEV are automatically configured for the Java project:
  • The compilation of the project indicates whether your project contains functions or controls that cannot be used in Java.
  • The creation of the archive makes it possible to generate a ".jar" file in the EXE directory of the project.
  • The setup module of the application only handles the files required for deploying the Java application.
Remark: We advise you create a new WINDEV project to develop a Java application rather than transform a WINDEV application into Java.

RAD available in Java

On a Java project that handles data files, you have the abomotu to use the Full il Application RAD or the Window RAD (Simple RAD).
To use a RAD pattern other than the Simple RAD, the generated code will have to be adapted to operate in a Java application.
Related Examples:
WD JavaMail Training (WINDEV): WD JavaMail
[ + ] This example is a Java example used to read and send emails.
WD Managing the Java errors Training (WINDEV): WD Managing the Java errors
[ + ] WINDEV enables you to develop Java applications without even knowing Java.
You benefit from the power and from the automated processes of the WINDEV environment.
One of the most useful automated processes is the automatic management of errors.
This example presents the operating mode and the implementation of the mechanism for managing the WINDEV errors.
Some illustrations allow you to understand the simplification performed when implementing this feature.
This project is configured to generate a Java archive.
WD Java Chart Designer Training (WINDEV): WD Java Chart Designer
[ + ] WINDEV enables you to create some Java applications without even knowing Java.
You program with a 5GL (WLanguage) and WINDEV generates the Java code.
The drawing functions of WINDEV are available in Java generation.
This example explains how to create charts with these drawing functions.
Three types of charts are presented in this example:
- the bar chart,
- the scatter chart,
- and the line chart.
WD JAVA Calls Training (WINDEV): WD JAVA Calls
[ + ] WD JAVA Calls is an example containing two configurations of project:
- A "Windows Application" configuration that is used to create the executable of the application
- A "Java Application" configuration that is used to create the Java archive (.JAR) of the application
This example is supplied with a JAR archive named "JavaFunction" external to the application.
It presents the call to the methods of classes of this JAR archive via the WLanguage function named JavaExecuteFunction.
This example also explains how a memory table can be filled (identical in Java mode and in Windows mode)
Minimum version required
  • Version 9
Comments
Click [Add] to post a comment

Last update: 06/22/2023

Send a report | Local help