Results 1 to 4 of 4
  1. #1
    Crisanto is offline Member
    Join Date
    Oct 2008
    Posts
    4
    Rep Power
    0

    Default Problem in setting Eclipse

    Hello
    I always get this error when I run my java program. Anyone can help me please?:


    java.lang.ExceptionInInitializerError
    Caused by: java.util.MissingResourceException: Can't find bundle for base name com.prpddmi.glinterface.GLinterface, locale en_US
    at java.util.ResourceBundle.throwMissingResourceExcep tion(Unknown Source)
    at java.util.ResourceBundle.getBundleImpl(Unknown Source)
    at java.util.ResourceBundle.getBundle(Unknown Source)
    at com.prpddmi.glinterface.glinterface.GLInterface.<c linit>(GLInterface.java:27)
    Exception in thread "main"

  2. #2
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    17,902
    Rep Power
    25

    Default

    Can you explain what you are doing, what program you are executing and how?
    What source is at line 27 in GLInterface.java?
    Are you missing a properties file that the app needs?

  3. #3
    Crisanto is offline Member
    Join Date
    Oct 2008
    Posts
    4
    Rep Power
    0

    Default

    Hello Norm,

    Here is the line 27 of the source: public static void main(String[] args) throws RemoteException {

    I have also the properties file that define the forname, database location. But it always sending error at line 27.

    It never get to this code

    import java.sql.Connection;
    import java.sql.DriverManager;
    import java.sql.ResultSet;
    import java.sql.SQLException;
    import java.sql.Statement;
    import java.text.DecimalFormat;
    import java.text.SimpleDateFormat;
    import java.util.Date;
    import java.util.ResourceBundle;

    public class GLInterface {
    public GLInterface() {
    try {
    // jbInit();
    } catch (Exception ex) {
    ex.printStackTrace();
    }
    }
    static Connection csConn;

    private static ResourceBundle resBundle = ResourceBundle
    .getBundle("com.prpddmi.glInterface.GLinterface");

    static String delimiter = resBundle.getString("Delimiter");

    public static void main(String[] args) throws RemoteException {

    // define date format for timestamping the output file
    String output;
    @SuppressWarnings("unused")
    String protectDate = null;
    // @SuppressWarnings("unused")
    SimpleDateFormat batchFormatter;
    SimpleDateFormat entryFormatter;
    SimpleDateFormat effectiveFormatter;
    SimpleDateFormat timeStampFormatter;

    timeStampFormatter = new SimpleDateFormat(resBundle
    .getString("TimeStamp"));
    batchFormatter = new SimpleDateFormat(resBundle.getString("BatchDate")) ;
    entryFormatter = new SimpleDateFormat(resBundle.getString("EntryDate")) ;
    effectiveFormatter = new SimpleDateFormat(resBundle
    .getString("EffectiveDate"));

    output = timeStampFormatter.format(new Date());

    PrintWriter write = null;
    try {
    //TODO: write a check to see if the file already exists
    write = new PrintWriter(new FileWriter(resBundle
    .getString("LogFileDir")

    + output + ".txt", true));
    } catch (IOException ex) {
    System.out.println("Error: " + ex.toString() + " "
    + ex.getMessage());
    }

    // set up 3G ODBC link
    String csdata = resBundle.getString("3GConnection");

    try {
    // begin creation of JDBC ODBC bridge
    Class.forName(resBundle.getString("ForName"));

    // set connection, include username, password if necessary
    csConn = DriverManager.getConnection(csdata, resBundle
    .getString("csadmin"), resBundle.getString("3gtest"));


    Thank for your help

  4. #4
    serjant's Avatar
    serjant is offline Senior Member
    Join Date
    Jun 2008
    Location
    Ukraine,Zaporozhye
    Posts
    487
    Rep Power
    7

    Default

    GLinterface_en_US.properties is not found in the package com.prpddmi.glInterface,check if it is there

Similar Threads

  1. Problem in setting icon for JFrame!
    By pranav13 in forum AWT / Swing
    Replies: 8
    Last Post: 11-04-2008, 06:24 AM
  2. Eclipse AST problem
    By java_neophyte in forum Eclipse
    Replies: 0
    Last Post: 10-04-2008, 12:49 PM
  3. Setting up CVS using Eclipse???
    By JavaInLove in forum Eclipse
    Replies: 1
    Last Post: 07-18-2008, 03:03 PM
  4. Setting up class path for Eclipse
    By tsantana in forum Eclipse
    Replies: 1
    Last Post: 04-07-2008, 08:05 PM
  5. Problem Setting offscreen background
    By D34N0 in forum Java Applets
    Replies: 1
    Last Post: 07-14-2007, 12:46 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •