|
|
|
|
|
|
|
|
|
Using Access Converter |
|
|
|
Options TabThe Options Tab has input controls to allow the user some control over some aspects of code generation. These options apply to both VB and Java Editions except where noted. Figure 1: Options Tab All Options except the Database API relate only to the Java Edition. These options will be ignored in the VB Edition. Convert To VB Only. Check this if you intend on using the Visual Basic code that is generated. The output is optimized for the VB development environment. Also, the Java code will not be generated. Convert Macros. Check this if you want the macros converted to code and included in the project. Convert Reports. Check this if you want the reports converted to Crystal Reports. One .rpt file will be created for each Access Report. Two version of Crystal Reports is supported: Crystal Reports Developer Edition v8.5 or Crystal Reports v9.0 (any edition). Version 9.0 also requires you to purchase and install a RCAPI (Report Creation API) License (manufacturer part number RAPNX90). If you are using v8.5 then make sure you do not have any other version installed on your machine. Use Grid for Continuous Forms. Check this if you want to switch continuous forms to using a Grid (Datasheet View). By default continuous forms will be converted to single forms with a navigation bar. Output Directory. Specifies a directory where the generated files will be placed. Leave this blank and they will be generated in the same directory as the database (.mdb file). Use Diamond ComboBox. Select when you want to use the Diamond Combobox which is a control that is similar to the built-in ComboBox but supports multiple columns. The API is also more similar to the Access ComboBox. Use Diamond ListBox. Select when you want to use the Diamond ListBox which is a control that is similar to the built-in ListBox but supports multiple columns. The API is also more similar to the Access ListBox. Database API. (VB Edtion only) Specifies what type of data bound controls to use in a VB project. For Access 2000 databases you must choose ADO. ADO is the only API abe to manipulate an Access 2000 database. For Access 97 databases you can choose between DAO 3.0 if you are using VB 5 or if you are using VB 6 you can choose DAO 3.51 or ADO. This option does not cause any changes to the VBA code itself. It only controls what type of controls are place on the VB Forms. Java Options TabThe Options Tab has input controls to allow the user some control over some aspects of code generation. Use Portable Fonts. Check this if you want to use the standard 3 fonts (Serif, SansSerif, and Monospaced) which are available across all platforms. One of the 3 font names will be used in place of the actual font name used in Access. This is the recommended option unless you are using specific font names which you know will be available on the platforms you will be deploying on. If you do not want the converter to modify font names then uncheck this option. Ignore On Error Resume Next. Check this if you want one error handler per function. All errors will then stop processing of code in that function. Uncheck this option if you want try...catch statements to surround each line of code. These statements simulate the On Error Resume Next in Java. Java Look and Feel. Java 2 can emulate the look and feel of multiple environments. Use this to designate what type of system the application should look and behave like. The system look and feel will make the application look like a native application on which ever platform it is executed on. Java IDE. If you will be doing further development in an IDE such as Visual Cafe or JBuilder you will want to set it to appropriate IDE. Some of the IDE's such as Visual Cafe need special formatting in order to get maximum use of that environment such as the visual screen builders. Java Package. Specifies the package that will be included in each Java class that is generated. Coding Style. CodingStyle controls the output style such as where {'s are placed. The JavaSoft style causes the { to appear on the same line as the keyword that starts the block. The Default style make the { begin on a new line just under the keyword that starts the block The two styles are illustrated below:
The number of spaces that each block should be indented can also be specified.
Defining JDBC Drivers and Data SourcesIn the same way a Visual Basic form might use an ODBC database driver to access a database that has been previously set up as an ODBC data source, the Java applet generated from a VB form can use a JDBC driver to access a predefined JDBC data source. The mapping between an Access Database and a JDBC driver needs to be defined. All mappings previously defined will be listed in the Java Data Sources listbox. If a listing is not there for a given database then the default JDBC-ODBC Bridge driver will be used. A Java Data Source is a specification that associates a particular Access database with the specific JDBC driver that is used to access that database. The name for the data source is the same name as the Access database file without the directory and without the .mdb extension. For example, a listing of Northwind (sun.jdbc.odbc.JdbcOdbcDriver) data source would cause the JDBC-ODBC Bridge driver to used to access the Northwind.mdb database. Adding JDBC DriversBefore you can create a Java Data Source, you must add a JDBC driver to Access Converter. To add a new JDBC driver, click the Drivers... button on the Options tab. Access Converter opens the Add JDBC Driver dialog. Adding JDBC Data Sources to Access ConverterAfter you've added at least one JDBC driver to Access Converter, you can create a Java Data Source. To add a new Java Data Source, click the Add... button on the Options tab. Access Converter displays the Add Data Source dialog. |
|
|
|
|
|
|