Creating a Non-databound Dialog in JOI (Functions/Subroutines/Programs)

How do I create a non-databound dialog in JOI?

 

The attached example shows how to create the following dialog that prompts the user for a beginning and an ending date:

 

 charset_utf-8

 

In Forte 3.0 or Netbeans 3.3.1 please mount the joi.jar archive and the directory that contains this unzipped example as follows:

 

 

charset_utf-8

 

 

Execute the TestingFrame class from the directory and you will get the following window:

 

charset_utf-8

 

This window is a test harness for calling the dialog window and displaying the returned results. In Forte 3.0 or Netbeans 3.3.1, double-click the "Get Dates" button at design time and you will see the following code behind the button:

 

charset_utf-8

 

The utilGetDatesDialog class is the non-databound dialog box that uses JOI controls to format the dates, but does not link back to a database. Please see the comments in that class' code, along with the ReadMe.doc document for the key elements of building a non-databound window.

 

On a separate note, since we all are used to Windows GUIs, the TestingFrame class contains code that changes the look and feel of the window to a Windows look and feel versus the default Java "Metal" look. This is the code that does that:

 

 

charset_utf-8

 

 

Hope this code is useful to you.

 

The JOI Development Team.

 

Click on the link below to download the files needed for this example:

 

{{kb0212_6.html; charset=utf-8}} 

  • kb/kb_articles/kb0212.txt
  • Last modified: 2024/01/30 13:36
  • by 127.0.0.1