Wait() in constructor

In my constructor I perform a call to an external package which starts a new thread of its own. This new thread (of which I have no control) performs a Listener call on my package when it is done.
What I want is for the constructor to return only when this listener call has been received. I tried using this code:
public class Foo implements BarListener{
  public Foo() {
    Bar otherPackage = new Bar();
    otherPackage.foobar();
    try {
      wait();
    } catch (InterruptedException ex) {
  public void otherPackageListener() {
    notify();
}This, however, throws an IllegalMonitorStateException and my program exits. Is there any way I can make this work as I want it to?

Seems I also needed a synchronized element around my notify().But what is the notify going to synchronize on? Not your Foo object, because you haven't finished its constructor yet.
You could put the wait in Bar.foobar(), synchronizing on the Bar object.
But I'd suggest that a better approach is to create a FooFactory, and put the waits in there. The reason is psychological: most people think of constructors as lightweight, and suspending a thread definitely isn't a lightweight operation.
Also, I notice that you ignore an InterruptedException, which is particularly bad in a constructor. If the calling thread is interrupted, then there's no way to know whether the object was correctly constructed. I

Similar Messages

  • When calling method error .class expected

    First the method I'm calling.
    public void ExeSqlStmt(String sqlStmt, String columnNames[], String connectString, String userName, String password,int numColumns)
    This compiles clean. The code that calls the method is giving me fits with expecting .class, expecting ), can not resolve symble and unexpected type.
    The offending line is near the bottom of the code.
    Thanks,
    -Rob
    package jdba;
    * Execute the sql statement
    // java imports
    import java.util.Vector;
    import java.awt.event.*;
    import java.awt.Toolkit;
    import java.awt.Container;
    import java.awt.BorderLayout;
    import java.awt.Color;
    import javax.swing.JScrollPane;
    import javax.swing.ScrollPaneConstants;
    import javax.swing.JTable;
    import javax.swing.JPanel;
    import javax.swing.JFrame;
    import javax.swing.JLabel;
    // sql imports
    import java.sql.ResultSet;
    import java.sql.SQLException;
    import java.sql.Statement;
    import java.sql.PreparedStatement;
    import java.sql.Connection;
    import java.sql.DriverManager;
    public class SqlUtil extends JPanel
      Connection conn;  // database connection object
      Statement stmt;   // statement object
      ResultSet rslt;   // result set object
      // create someplace to put dat
      Vector data;     //    = new Vector();
      Vector columns;  //    = new Vector();
      Vector colHeads; //    = new Vector();     
      public SqlUtil()
        // setup panel
        JPanel sqlPanel = new JPanel(false);
        sqlPanel.setLayout(new BorderLayout());
        setBackground(Color.white);
        setForeground(Color.black);
      public void ExeSqlStmt(String sqlStmt, String columnNames[], String connectString, String userName, String password,int numColumns)
        data     = new Vector();
        columns  = new Vector();
        colHeads = new Vector();
        try
          // connect to database
          DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
          Connection conn = DriverManager.getConnection(connectString, userName, password);
          // select data into object
          stmt = conn.createStatement();
          rslt = stmt.executeQuery(sqlStmt);
          while (rslt.next())
            columns = new Vector();
            for ( int i=0; i<numColumns; i++ )
              colHeads.addElement(columnNames); // column heads
    columns.addElement(rslt.getObject(i+1)); // get the Object at i+1
    } // end for
    data.addElement(columns);
    // create the table
    JTable table = new JTable(data,colHeads);
    // add table to scroll pane
    int v = ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED;
    int h = ScrollPaneConstants.HORIZONTAL_SCROLLBAR_AS_NEEDED;
    JScrollPane jsp = new JScrollPane(table,v,h);
    // Add scroll pane to content pane
    add(jsp, BorderLayout.CENTER);
    // close the result set and close the statement
    rslt.close();
    stmt.close();
    } catch (SQLException ex)
    String msg = "SQL error: "+ex.toString();
    } catch (Exception ex)
    String msg = "Error: "+ex.toString();
    } // end constructor
    } // end SqlUtil class
    // then we have the code that is calling and getting the errors
    package jdba;
    // java imports
    import java.util.Vector;
    import java.awt.event.*;
    import java.awt.Toolkit;
    import java.awt.Container;
    import java.awt.BorderLayout;
    import java.awt.Color;
    import javax.swing.JScrollPane;
    import javax.swing.ScrollPaneConstants;
    import javax.swing.JTable;
    import javax.swing.JPanel;
    import javax.swing.JFrame;
    import javax.swing.JLabel;
    // sql imports
    import java.sql.ResultSet;
    import java.sql.SQLException;
    import java.sql.Statement;
    import java.sql.PreparedStatement;
    import java.sql.Connection;
    import java.sql.DriverManager;
    // rollback contention
    public class RollbackContention extends JPanel
    Connection conn; // database connection object
    Statement stmt; // statement object
    ResultSet rslt; // result set object
    //private vars
    private String userName = "[cut]";
    private String password = "[cut]";
    private String sid = "rob";
    private String port = "1521";
    private String server = "[cut]";
    private String connectString = "jdbc:oracle:thin:@"+server+":"+port+":"+sid;
    private int numCols = 3;
    private String sqlStmt = null;
    private String prompt = null;
    private String colNames[] = {"name","waits","gets"};
    // constructor
    public RollbackContention()
    SqlUtil exeStmt = new SqlUtil();
    sqlStmt = "select name, waits, gets";
    sqlStmt = sqlStmt + " from v$rollstat, v$rollname";
    sqlStmt = sqlStmt + " where v$rollstat.usn = v$rollname.usn";
    // here is the offending line.
    exeStmt.exeSqlStmt(sqlStmt, colNames[], connectString, userName, password, 3);
    // loop through and display the rollback segments

    In your call your referencing the array as colNames[] - it should be colNames (no []'s )
    exeStmt.exeSqlStmt(sqlStmt, colNames, connectString, userName, password, 3);

  • Singleton with timeout

    Hi!
    I have to implement Singleton pattern, but I have the following restriction: The getInstance() method should not stop the entire application.
    I wrote the following code, to achieve my objective:
    public class ServiceProvider {
        private static Service service;
        private static final PrivateClass singletonProvider = new PrivateClass();
        private ServiceProvider() {}
        public static synchronized Service getInstance() throws MyException {
            if (service == null) {
                Thread thread = new Thread(singletonProvider);
                thread.start();
                try {
                    // Ten seconds for the construction of the service field.
                    Thread.sleep(10000);
                } catch (InterruptedException ex) {
                    throw new MyException("InterruptedException!!!", ex);
                // Is the verification based on Thread.isAlive() safe?
                // I am not sure. Please, tell me.
                if (!thread.isAlive()) {
                    if (service == null) {
                        throw new MyException("Service is still not available");
                    } else {
                        return service;
                } else {
                    throw new MyException("Service is still not available");
            } else {
                return service;
        // Using a private class I do not need to expose the public run() method.
        private static class PrivateClass implements Runnable {
            private PrivateClass() {}
            private synchronized Service defineInstance() throws MyException {
                if (service == null) {
                    service = new Service();
                return service;
            public synchronized void run() {
                try {
                    singletonProvider.defineInstance();
                } catch (Exception e) {
                    e.printStackTrace();
    public class Service {
        public Service() throws MyException {
            try {
                // Simulating a problem: the constructor is taking 20 seconds to be finished.
                Thread.sleep(20000);
            } catch (InterruptedException ex) {
                throw new MyException("InterruptedException in the Service constructor", ex);
        public void method() {
    }I am just not sure if the verification based on Thread.isAlive() is safe.
    Thanks!!!

    malcolmmc wrote:
    This sounds all very familiar. This is an occasion to use wait and notify to synchronize with your background thread. For one thing, the way you've written it, the caller to getInstance() will wait 10 seconds even if the service instance is loaded much faster than that.Yes... I tried what you are suggesting, but the problem is that using wait and notify I have to lock the PrivateClass field of the ServiceProvider class. So, since the fields should be locked, the call to the Service constructor will also be locked, and then I always have to wait the constructor finishes, no matter how I implement the logic of wait and notify.
    So instead of sleep(10000L) use wait(10000L). Then when your loader sets the instance variable it calls notify on the same monitor. This will wake the main thread up if it's waiting.
    You also need to deal with the case where getInstance is called a second time either when the first call to getInstance() is waiting, or after the first call has given up.I did the following solution instead. It works fine:
    public class ServiceProvider {
        private static Service service;
        private static final PrivateClass privateClass = new PrivateClass();
        private ServiceProvider() {}
        public static synchronized Service getInstance() throws MyException {
            if (service == null) {
                ScheduledThreadPoolExecutor executor = new ScheduledThreadPoolExecutor(1);
                AnotherPrivateClass anotherPrivateClass = new AnotherPrivateClass();
                Future future = executor.submit(anotherPrivateClass);
                try {
                    // Ten seconds for the construction of the service field.
                    future.get(10000,TimeUnit.MILLISECONDS);
                } catch (TimeoutException ex) {
                    throw new MyException("Service is still not available");
                } catch (ExecutionException ex) {
                    throw new MyException("Service is still not available");
                } catch (InterruptedException ex) {
                    throw new MyException("Service is still not available");
                } finally {
                    executor.shutdown();
                // Is the verification based on Thread.isAlive() safe?
                // I am not sure. Please, tell me.
                if (!anotherPrivateClass.thread.isAlive()) {
                    if (service == null) {
                        throw new MyException("Service is still not available");
                    } else {
                        return service;
                } else {
                    throw new MyException("Service is still not available");
            } else {
                return service;
        private static class AnotherPrivateClass implements Runnable {
            private Thread thread;
            private AnotherPrivateClass() {
                this.thread = new Thread(privateClass);
            public synchronized void run() {
                thread.start();
                try {
                    synchronized (privateClass) {
                        while (!privateClass.done) {
                            privateClass.wait();
                        if (service == null) {
                            privateClass.done = false;
                } catch (InterruptedException ex) {
                    ex.printStackTrace();
        // Using a private class I do not need to expose the public run() method.
        private static class PrivateClass implements Runnable {
            boolean done = false;
            private PrivateClass() {}
            private synchronized void defineInstance() throws MyException {
                if (service == null) {
                    service = new Service();
            public synchronized void run() {
                try {
                    privateClass.defineInstance();
                } catch (Exception e) {
                    e.printStackTrace();
                done = true;
                this.notify();
    }

  • How to use wait/nofity in socket server

    Dear all
    that is one of sample code from a book which's use mutil connection with socket program , but i if it is possible to use wait and nofity to controle client activety by wait and notify in this sample code ?
    some idea hope someone give me a help please
    import java.net.*;
    import java.io.*;
    * Threaded Echo Server, pre-allocation scheme.
    * Each Thread waits in its accept() call for a connection; this synchronizes
    * on the serversocket when calling its accept() method.
    * @author Ian F. Darwin.
    public class EchoServerThreaded2 {
         public static final int ECHOPORT = 7;
         public static final int NUM_THREADS = 4;
         /** Main method, to start the servers. */
         public static void main(String[] av)
              new EchoServerThreaded2(ECHOPORT, NUM_THREADS);
         /** Constructor */
         public EchoServerThreaded2(int port, int numThreads)
              ServerSocket servSock;
              Socket clientSocket;
              try {
                   servSock = new ServerSocket(ECHOPORT);
              } catch(IOException e) {
                   /* Crash the server if IO fails. Something bad has happened */
                   System.err.println("Could not create ServerSocket " + e);
                   System.exit(1);
                   return;     /*NOTREACHED*/
              // Create a series of threads and start them.
              for (int i=0; i<numThreads; i++) {
                   new Thread(new Handler(servSock, i)).start();
         /** A Thread subclass to handle one client conversation. */
         class Handler extends Thread {
              ServerSocket servSock;
              int threadNumber;
              /** Construct a Handler. */
              Handler(ServerSocket s, int i) {
                   super();
                   servSock = s;
                   threadNumber = i;
                   setName("Thread " + threadNumber);
              public void run()
                   /* Wait for a connection. Synchronized on the ServerSocket
                    * while calling its accept() method. */
                   while (true){
                        try {
                             System.out.println( getName() + " waiting");
                             Socket clientSocket;
                             // Wait here for the next connection.
                             synchronized(servSock) {
                                  clientSocket = servSock.accept();
                             System.out.println(getName() + " starting, IP=" +
                                  clientSocket.getInetAddress());
                             DataInputStream is = new DataInputStream(
                                  clientSocket.getInputStream());
                             PrintStream os = new PrintStream(
                                  clientSocket.getOutputStream(), true);
                             String line;
                             while ((line = is.readLine()) != null) {
                                  os.print(line + "\r\n");
                                  os.flush();
                             System.out.println(getName() + " ENDED ");
                             clientSocket.close();
                        } catch (IOException ex) {
                             System.out.println(getName() + ": IO Error on socket " + ex);
                             return;
    }if i add end of my code like this and then the error message indicat that
    java.lang.IllegalMonitorStateException: current thread not owner
    try{
                        clientSocket.wait();
                 }catch(InterruptedException e){
                                              clientSocket.close();
                                              clientSocket.notify();
                                            }

    Why? Closing the socket will cause the client to return from reading the socket with a null or zero or EOFException. You don't need anything else.
    In any case notifying the clientSocket will only wakeup threads in the current JVM that are waiting on it. This mechanism isn't magic, and it can't wake up another JVM.

  • How to force to wait and get input from a jframe-jpanel?

    I would like to use a jframe-jpanel to get user input instead of using JOptionPane.showInputDialog since there will be more than 1 input.
    But I could not do it. The code reads the panel lines and passes to other lines below without waiting for the okay button to be pressed.
    This is the part of code of my main frame;
    jLabel10.setText(dene.toString());
    if (dene == 0) {
    // todo add button input panel
    //String todo_write = JOptionPane.showInputDialog("Please enter a todo item");
    JFrame frameTodoAddInput = new JFrame( "Please input..." );
    TodoAddAsk1JPanel todoaddpanel = new TodoAddAsk1JPanel();
    frameTodoAddInput.add(todoaddpanel);
    frameTodoAddInput.setSize( 600, 200 ); // set frame size
    frameTodoAddInput.setLocation(300, 300);
    //String todo_write = todoaddpanel.getNewTodoItem();
    String todo_write = todoaddpanel.getNewTodoItem();
    jLabel10.setText("Satir 1822 de".concat(todo_write));
    // end of todo add button input panel
    todoTextPane1.setText(todo_write);
    This is the code of input panel;
    * TodoAddAsk1JPanel.java
    * Created on May 6, 2007, 12:03 AM
    package javaa;
    public class TodoAddAsk1JPanel extends javax.swing.JPanel {
    /** Creates new form TodoAddAsk1JPanel */
    public TodoAddAsk1JPanel() {
    initComponents();
    private String NewTodoItem = "";
    public String getNewTodoItem() {
    NewTodoItem = ANewTodoItemTextField.getText();
    return this.NewTodoItem;
    /** This method is called from within the constructor to
    * initialize the form.
    * WARNING: Do NOT modify this code. The content of this method is
    * always regenerated by the Form Editor.
    // <editor-fold defaultstate="collapsed" desc=" Generated Code ">
    private void initComponents() {
    jLabel1 = new javax.swing.JLabel();
    ANewTodoItemTextField = new javax.swing.JTextField();
    jLabel2 = new javax.swing.JLabel();
    PriorityComboBox = new javax.swing.JComboBox();
    jLabel3 = new javax.swing.JLabel();
    DayValueComboBox = new javax.swing.JComboBox();
    MonthValueComboBox = new javax.swing.JComboBox();
    YearValueComboBox = new javax.swing.JComboBox();
    OkayButton = new javax.swing.JButton();
    CancelButton = new javax.swing.JButton();
    TimeValueComboBox = new javax.swing.JComboBox();
    jLabel1.setText("Please enter a todo item:");
    jLabel2.setText("Please select its priority level:");
    PriorityComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "A", "B", "C" }));
    jLabel3.setText("Please select its due date:");
    DayValueComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", "25", "26", "27", "28", "29", "30", "31" }));
    MonthValueComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December" }));
    YearValueComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "2007", "2008", "2009", "2010", "2011", "2012", "2013", "2014", "2015", "2016", "2017", "2018", "2019", "2020", "2021", "2022", "2023", "2024", "2025", "2026", "2027", "2028", "2029", "2030", "2031", "2032", "2033", "2034", "2035", "2036", "2037", "2038", "2039", "2040", "2041", "2042", "2043", "2044", "2045", "2046", "2047", "2048", "2049", "2050", "2051", "2052", "2053", "2054", "2055", "2056", "2057", "2058", "2059", "2060", "2061", "2062", "2063", "2064", "2065", "2066", "2067", "2068", "2069", "2070" }));
    OkayButton.setText("OK");
    OkayButton.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    OkayButtonActionPerformed(evt);
    CancelButton.setText("Cancel");
    TimeValueComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "08:30", "09:00", "09:30", "10:00", "10:30", "11:00", "11:30", "12:00", "12:30", "13:00", "13:30", "14:00", "14:30", "15:00", "15:30", "16:00", "16:30", "17:00", "17:30", "18:00", "18:30", "19:00", "19:30", "20:00", "20:30", "21:00", "21:30", "22:00", "22:30", "23:00", "23:30", "00:00", "00:30", "01:00", "01:30", "02:00", "02:30", "03:00", "03:30", "04:00", "04:30", "05:00", "05:30", "06:00", "06:30", "07:00", "07:30", "08:00" }));
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
    this.setLayout(layout);
    layout.setHorizontalGroup(
    layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
    .addGroup(layout.createSequentialGroup()
    .addContainerGap()
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
    .addComponent(jLabel1, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 142, Short.MAX_VALUE)
    .addComponent(jLabel2, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
    .addComponent(jLabel3, javax.swing.GroupLayout.DEFAULT_SIZE, 142, Short.MAX_VALUE))
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
    .addComponent(PriorityComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
    .addComponent(ANewTodoItemTextField, javax.swing.GroupLayout.PREFERRED_SIZE, 279, javax.swing.GroupLayout.PREFERRED_SIZE)
    .addGroup(layout.createSequentialGroup()
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
    .addComponent(OkayButton, javax.swing.GroupLayout.Alignment.LEADING)
    .addGroup(layout.createSequentialGroup()
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 133, Short.MAX_VALUE)
    .addComponent(CancelButton))
    .addGroup(javax.swing.GroupLayout.Alignment.LEADING, layout.createSequentialGroup()
    .addComponent(DayValueComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addComponent(MonthValueComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
    .addComponent(YearValueComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
    .addGap(13, 13, 13)
    .addComponent(TimeValueComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
    .addGap(42, 42, 42)))
    .addContainerGap())
    layout.setVerticalGroup(
    layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
    .addGroup(layout.createSequentialGroup()
    .addContainerGap()
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
    .addComponent(ANewTodoItemTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
    .addComponent(jLabel1))
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
    .addComponent(jLabel2)
    .addComponent(PriorityComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
    .addComponent(jLabel3)
    .addComponent(DayValueComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
    .addComponent(MonthValueComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
    .addComponent(YearValueComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
    .addComponent(TimeValueComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
    .addGap(18, 18, 18)
    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
    .addComponent(OkayButton)
    .addComponent(CancelButton))
    .addContainerGap())
    }// </editor-fold>
    private void OkayButtonActionPerformed(java.awt.event.ActionEvent evt) {                                          
    // TODO add your handling code here:
    NewTodoItem = ANewTodoItemTextField.getText();
    // Variables declaration - do not modify
    private javax.swing.JTextField ANewTodoItemTextField;
    private javax.swing.JButton CancelButton;
    private javax.swing.JComboBox DayValueComboBox;
    private javax.swing.JComboBox MonthValueComboBox;
    private javax.swing.JButton OkayButton;
    private javax.swing.JComboBox PriorityComboBox;
    private javax.swing.JComboBox TimeValueComboBox;
    private javax.swing.JComboBox YearValueComboBox;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel3;
    // End of variables declaration
    I want to get the resulted input of "NewTodoItem"
    Thanks in advance for your kind help.
    Guven

    Thank you very much for your help. But I would like
    to get 3 inputs from 1 window at the same time and I
    could not find any example code for JDialog for more
    than 1 input. If any body can show how to write this
    code, it would be appreciated.
    ThanksYou can write your own. A JDialog is a container just look a JFrame is.

  • Error in Constructor

    So i mod GTA IV with c#
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;
    using System.IO;
    using System.Windows.Forms;
    using System.Drawing;
    using System.Diagnostics;
    using System.Collections.Generic;
    using GTA;
    using GTA.Native;
    namespace Beggar
    public class ambBeggar : Script
    bool tb = false;
    bool bp = true;
    Ped rped;
    AnimationSet beggarsitting;
    AnimationSet beggarstanding;
    Keys begkey;
    GTA.Timer gmoney;
    public ambBeggar()
    gmoney.Interval = 120000;
    gmoney.Tick += gmoney_Tick;
    begkey = Settings.GetValueKey("Beg", "Beggar Mod", Keys.B);
    if(!File.Exists(Settings.Filename))
    Settings.SetValue("Beg", "Beggar Mod", Keys.B);
    this.Interval = 100000;
    this.Tick += new EventHandler(ambBeggar_get);
    this.ConsoleCommand += new ConsoleEventHandler(ambBeggar_ConsoleCommand);
    public void ambBeggar_get(object sender, EventArgs e)
    if(tb == true && !rped.Exists())
    rped = World.GetClosestPed(Player.Character.Position, 30);
    public void gmoney_Tick(object sender, EventArgs e)
    if (rped.Exists())
    rped.Task.GoTo(Player.Character.Position.Around(2));
    Pickup.CreateMoneyPickup(rped.Position, 1000);
    rped.NoLongerNeeded();
    public void ambBeggar_ConsoleCommand(object sender, ConsoleEventArgs e)
    if(e.Command == "t_beggar" && tb == false)
    tb = true;
    Function.Call("REQUEST_ANIMS", "amb@beg_sitting");
    //Function.Call("REQUEST_ANIMS","amb@beg_standing");
    if (Function.Call<bool>("HAVE_ANIMS_LOADED","amb@beg_standing") /*&& Function.Call<bool>("HAVE_ANIMS_LOADED","amb@beg_sitting")*/)
    msg("Press" + begkey.ToString() + "To Beg", 5000);
    beggarsitting = new AnimationSet("amb@beg_sitting");
    //beggarstanding = new AnimationSet("amb@beg_standing");
    Player.Character.Animation.Play(beggarsitting, "beggar_sit", 8, AnimationFlags.Unknown05);
    while(tb == true)
    beg_playing();
    if(Game.isKeyPressed(begkey))
    Player.Character.Task.ClearAllImmediately();
    Player.Character.Task.PlayAnimation(beggarsitting, "beggar_beg", 8);
    gmoney.Start();
    while (bp == true) Wait(0);
    Player.Character.Task.ClearAllImmediately();
    Player.Character.Task.PlayAnimation(beggarsitting, "beggar_sit", 8,AnimationFlags.Unknown05);
    if(Player.Character.isDead)
    cleanup();
    if(e.Command == "t_beggar" && tb == true)
    cleanup();
    public void msg(string sMsg, int time)
    Function.Call("PRINT_STRING_WITH_LITERAL_STRING_NOW", new Parameter[] { "STRING", sMsg, time, 1 });
    public void beg_playing()
    if (GTA.Native.Function.Call<bool>("IS_CHAR_PLAYING_ANIM", Player.Character, "amb@beg_sitting", "beggar_beg") == false)
    bp = false;
    if (GTA.Native.Function.Call<bool>("IS_CHAR_PLAYING_ANIM", Player.Character, "amb@beg_sitting", "beggar_beg") == true)
    bp = true;
    public void cleanup()
    tb = false;
    gmoney.Stop();
    Every time i run the game i get "Error in Constructor" and "Object reference not set to an instance of an object"

    please verify 
    this.Interval = 100000;
    Interval, member of the class or no ?
    Mark as answer or vote as helpful if you find it useful | Ammar Zaied [MCP]

  • Wait() and notifyall() problem in servlet.

    Can anyone help me with this.....
    I am creating an application which has one gateway inside which
    handles for logger, dbmodule etc are made and passed to biz logic.
    This biz logic using logger obj made in gateway, does the logging.
    Now i hv to do serial implementation of logging i.e I have
    a static member which is of type Vector, which will hold
    a list of messages and associated parameters. The write() method will
    create a formatted message with all values inserted, all prefixes and
    suffixes added, etc. Then it will append the message to the Vector of
    messages. And there will be a separate thread, which will be started
    the
    first time the first Logger instance is created. This thread will keep
    picking up messages from this Vector in FIFO order and writing them
    out.Mind you, I don't mean i need to use a single shared Logger
    instance.
    Separate Logger instances must be used to hold separate values for
    sessionID, username, etc. Only the internal logging I/O stream handle
    should be shared.
    For this what i hv created logger class as follows:
    logger {
    SyslogAppender SA;
    logger() {
    new SA;
    ThreadGroup TG = new ThreadGroup("string");
    Logging target = new Logging();
    Thread DT = new Thread(TG, target, "daemon");
    DT.setDaemon(true);
    DT.start();
    class write {
    write() {
    //initialisation;
    void writetovector() {
    addtovector
    notifyall;
    class logging implements runnable {
    public void run() {
    while(vector is not empty){
    log
    synchronised(this){
    wait();
    Now in the servlet, in init(), logger is called with this constructor
    and therefore there is only one instance of syslog appender to log in
    syslog.
    In service i just call the function writetovector through a method in
    logger.
    However when i run the implemented version of this, logging does not
    take place.
    I feel my implementation of wait and notifyall is not correct. Or is
    there any other problem?
    thanx in advance

    There are many problems with your code. It looks like you retyped it, and it now contains many syntax errors. Two problems I can see, though, are that you do not call notifyAll from synchronized code, and your call to wait is not in a loop.

  • Effect of super() in JDialog constructor on focusability/modality

    Hello again,
    this is a JFrame which calls a JDialog which calls a JDialog.
    Using super(...) in the constructor of SecondDialog makes this dialog
    unfocusable as long as FirstDialog is shown. Without super(...) one can freely
    move between the dialogs.
    Can somebody exlain what "super" does to produce this difference?
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    public class SuperConstructor extends JFrame {
      public SuperConstructor() {
        setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
        setSize(300,300);
        setTitle("Super constructor");
        Container cp= getContentPane();
        JButton b= new JButton("Show dialog");
        b.addActionListener(new ActionListener() {
          public void actionPerformed(ActionEvent evt) {
         new FirstDialog(SuperConstructor.this);
        cp.add(b, BorderLayout.SOUTH);
        setVisible(true);
      public static void main(String args[]) {
        EventQueue.invokeLater(new Runnable() {
          public void run() {
         new SuperConstructor();
      class FirstDialog extends JDialog {
        public FirstDialog(final Frame parent) {
          super(parent, "FirstDialog");
          setSize(200,200);
          setLocationRelativeTo(parent);
          setModalityType(Dialog.ModalityType.DOCUMENT_MODAL);
          JButton bNext= new JButton("Show next dialog");
          bNext.addActionListener(new ActionListener() {
         public void actionPerformed(ActionEvent evt) {
           new SecondDialog(parent, false);
          add(bNext, BorderLayout.SOUTH);
          setVisible(true);
      int i;
      class SecondDialog extends JDialog {
        public SecondDialog(Frame parent, boolean modal) {
          super(parent); // Makes this dialog unfocusable as long as FirstDialog is 
    shown
          setSize(200,200);
          setLocation(300,50);
          setModal(modal);
          setTitle("SecondDialog "+(++i));
          JButton bClose= new JButton("Close");
          bClose.addActionListener(new ActionListener() {
         public void actionPerformed(ActionEvent evt) {
           dispose();
          add(bClose, BorderLayout.SOUTH);
          setVisible(true);
    }

    nice day,
    there are three areas of get potential problem
    1/ FirstDialog helt pernament MODALITY, SecondDialog to have to same ...
    2/ there isn't something about change Window focus (if Parent inside of EDT, then you alyway lost focus, meaning SecondDialog)
    3/ constructor super inside class doesn't works, block move focus to the SecondDialog (and nonModal)
    ... but
    4/ here is second coins_side [http://forums.sun.com/thread.jspa?messageID=11020377#11020377]
    5/ in this form is my example returns similair result, isn't possible setWindow focus for visible JDialog (sure, remove Extend JDialog and create separate constuctor for JDialog, solve that)
    6/ maybe I'm wrong
    package JDialog;
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    * Parent Modal Dialog. When in modal mode, this dialog
    * will block inputs to the "parent Window" but will
    * allow events to other components
    * @see javax.swing.JDialog
    public class PMDialog extends JDialog {
        private static final long serialVersionUID = 1L;
        private boolean modal = false;
        private WindowAdapter parentWindowListener;
        private Window owner;
        private JFrame blockedFrame = new JFrame("No blocked frame");
        private JFrame noBlockedFrame = new JFrame("Blocked Frame");
        public PMDialog() {
            noBlockedFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
            noBlockedFrame.getContentPane().add(new JButton(new AbstractAction("Test button") {
                private static final long serialVersionUID = 1L;
                @Override
                public void actionPerformed(ActionEvent evt) {
                    System.out.println("Non blocked button pushed");
                    /*if (blockedFrame.isVisible()) {
                        noBlockedFrame.setVisible(false);
                    } else {
                        blockedFrame.setVisible(true);
                    noBlockedFrame.setVisible(true);
                    blockedFrame.setVisible(true);
            noBlockedFrame.setSize(200, 200);
            noBlockedFrame.setVisible(true);
            blockedFrame.setDefaultCloseOperation(JFrame.HIDE_ON_CLOSE);
            blockedFrame.getContentPane().add(new JButton(new AbstractAction("Test Button") {
                private static final long serialVersionUID = 1L;
                @Override
                public void actionPerformed(ActionEvent evt) {
                    final PMDialog pmd = new PMDialog(blockedFrame, "Partial Modal Dialog", true);
                    pmd.setSize(200, 100);
                    pmd.setLocationRelativeTo(blockedFrame);
                    pmd.getContentPane().add(new JButton(new AbstractAction("Test button") {
                        private static final long serialVersionUID = 1L;
                        @Override
                        public void actionPerformed(ActionEvent evt) {
                            System.out.println("Blocked button pushed");
                            pmd.setVisible(false);
                            blockedFrame.setVisible(false);
                            noBlockedFrame.setVisible(true);
                    pmd.setDefaultCloseOperation(PMDialog.DISPOSE_ON_CLOSE);
                    pmd.setVisible(true);
                    System.out.println("Returned from Dialog");
            blockedFrame.setSize(200, 200);
            blockedFrame.setLocation(300, 0);
            blockedFrame.setVisible(false);
        public PMDialog(JDialog parent, String title, boolean isModal) {
            super(parent, title, false);
            initDialog(parent, title, isModal);
        public PMDialog(JFrame parent, String title, boolean isModal) {
            super(parent, title, false);
            initDialog(parent, title, isModal);
        private void initDialog(Window parent, String title, boolean isModal) {
            owner = parent;
            modal = isModal;
            parentWindowListener = new WindowAdapter() {
                @Override
                public void windowActivated(WindowEvent e) {
                    if (isVisible()) {
                        System.out.println("Dialog.getFocusBack()");
                        getFocusBack();
        private void getFocusBack() {
            Toolkit.getDefaultToolkit().beep();
            super.setVisible(false);
            super.pack();
            super.setLocationRelativeTo(owner);
            super.setVisible(true);
            //super.toFront();
        @Override
        public void dispose() {
            owner.setEnabled(true);
            owner.setFocusableWindowState(true);
            super.dispose();
        @Override
        @SuppressWarnings("deprecation")
        public void hide() {
            owner.setEnabled(true);
            owner.setFocusableWindowState(true);
            super.hide();
        @Override
        public void setVisible(boolean visible) {
            boolean blockParent = (visible && modal);
            owner.setEnabled(!blockParent);
            owner.setFocusableWindowState(!blockParent);
            super.setVisible(visible);
            if (blockParent) {
                System.out.println("Adding listener to parent ...");
                owner.addWindowListener(parentWindowListener);
                try {
                    if (SwingUtilities.isEventDispatchThread()) {
                        System.out.println("EventDispatchThread");
                        EventQueue theQueue = getToolkit().getSystemEventQueue();
                        while (isVisible()) {
                            AWTEvent event = theQueue.getNextEvent();
                            Object src = event.getSource();
                            if (event instanceof ActiveEvent) {
                                ((ActiveEvent) event).dispatch();
                            } else if (src instanceof Component) {
                                ((Component) src).dispatchEvent(event);
                    } else {
                        System.out.println("OUTSIDE EventDispatchThread");
                        synchronized (getTreeLock()) {
                            while (isVisible()) {
                                try {
                                    getTreeLock().wait();
                                } catch (InterruptedException e) {
                                    break;
                } catch (Exception ex) {
                    ex.printStackTrace();
                    System.out.println("Error from EDT ... : " + ex);
            } else {
                System.out.println("Removing listener from parent ...");
                owner.removeWindowListener(parentWindowListener);
                owner.setEnabled(true);
                owner.setFocusableWindowState(true);
        @Override
        public void setModal(boolean modal) {
            this.modal = modal;
        public static void main(String args[]) {
            PMDialog pMDialog = new PMDialog();
    }

  • My wait() thread never wakes up with notify()

    In the code below, I'm trying to wake up the DispatchThread whenever the add method is called in the PriorityQueue. For some reason the notify() method is not unblocking the thread. All I can figure is that the reference to the thread in notify() is incorrect. Can anyone find the problem with the code?
    import java.util.TreeSet;
    public class PriorityQueue{
      private TreeSet queue;
      private DispatchThread d_Thread;
      private Thread d_thread;
      //default constructor
         PriorityQueue()
           queue = new TreeSet();
         d_Thread = new DispatchThread(this);
         public  void add(Object anobject)
        synchronized (this.d_Thread)
            queue.add(anobject);
          this.d_Thread.notify();
          System.out.println(anobject+" added to queue now");
          try
            Thread.sleep(500);
          catch (InterruptedException e){}
         static void main(String args[])
              PriorityQueue intTest = new PriorityQueue();
              intTest.add(new Integer(25));
              intTest.add(new Integer(35));
              intTest.add(new Integer(6));
    class DispatchThread implements Runnable{
      private PriorityQueue queue;
      private Thread d_Thread;
      public DispatchThread(PriorityQueue queue)
        this.queue = queue;
        d_Thread = new Thread(this);
        d_Thread.start();
      public void run()
        while(true)
          synchronized (this.d_Thread)
            try
              System.out.println("about to wait - dispatch thread");
              this.d_Thread.wait();
              System.out.println("just woke up dispatch thread"); //never makes it this far
    //do some dispatching operations here
            catch(InterruptedException ie){}
    }

    When you call the wait method, you use the thread you create in the constructor of DispatchThread.
    When you call the notify method, you use another lock, the Dispatch object itself.
    And notify and wait are methods defined in Object. It's rarely you would use a thread object as a lock.
    You can make you code work if you do this in DispatchThread:
    synchronized (this) {
      try {
        System.out.println("about to wait - dispatch thread");
        wait();
    }because now you use the same lock both places.

  • Static Thread + Thread() constructor

    Hi!
    I want to make a thread which will behave similar to "awt event dispatching thread". I want it to do some tasks by simply passing a runnable to method named addTask (this is similar to invokeLater or invokeAndWait in EventQueue)...
    QUESTION #1
    I know how to make thread waiting for task. What I want to know is your opinion about the way of creating static thread. Is this the right way how to do that? :
    public class TaskThreadHandler implements Runnable {
         private static final Runnable r = new TaskThreadHandler();
         private static final Thread t = new Thread(r);
         public void run(){/*thread start point*/}
         public void addTask(Runnable r){
              /*This will force the thread to do the task*/
    }QUESTION #2
    What is the aim of the Thread( void ) constructor? Where starts such a Thread if I call new Thread().start() (I didn't pass there any Runnable, so where??)?
    Many thanks
    Miso

    Something like this:
    public class TaskThreadHandler {
      private Thread myThread;
    // constructor is private because we always construct from getInstance();
    private TaskThreadHandler() {
          myThread = new Thread(new Runnable() {
              public void run() {
                   go();
                }, "Worker thread");
           myThread.start();
    private static TaskThreadHandler inst;
    * Return single instance of class
    public synchronized TaskThreadHandler getInstance() {
          if(inst == null)
             inst = new TaskThreadHandler();
         return inst;
    private BlockingQueue<Runnable> queue = new LinkedListBlockingQueue();
    // thread body runs until thread interrupted.
    private void go() {
        try {
           while(!myThread.interrupted()) {
              queue.take().run();
        } catch(InterruptedException e) {
    etc.

  • Thread Waiting on Condition

    From the following thread dump, my thread is waiting on some condition due to the deserialization process. How do I find out what that condition is?
    "EventSet Archiving" prio=1 tid=0x081cfb28 nid=0x31ab waiting on condition [619a4000..619a5854]
            at sun.reflect.GeneratedSerializationConstructorAccessor2926.newInstance(Unknown Source)
            at java.lang.reflect.Constructor.newInstance(Constructor.java:274)
            at java.io.ObjectStreamClass.newInstance(ObjectStreamClass.java:788)
            at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1631)
            at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274)
            at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1845)
            at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1769)
            at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1646)
            at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274)
            at java.io.ObjectInputStream.readObject(ObjectInputStream.java:324)
            at java.util.HashMap.readObject(HashMap.java:1006)
            at sun.reflect.GeneratedMethodAccessor404.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:324)
            at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:838)
            at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1746)
            at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1646)
            at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274)
            at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1845)
            at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1769)
            at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1646)
            at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274)
            at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1845)
            at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1769)
            at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1646)
            at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274)
            at java.io.ObjectInputStream.readObject(ObjectInputStream.java:324)
            at com.dartcontainer.mdc.picaps.dbaccess.EventTable$1.get(EventTable.java:49)
            at com.dartcontainer.mdc.picaps.dbaccess.EventTable$1.get(EventTable.java:44)
            at com.dartcontainer.mdc.picaps.dbaccess.Cache.get(Cache.java:110)
            at com.dartcontainer.mdc.picaps.dbaccess.EventTable.resultToObject(EventTable.java:43)
            at com.dartcontainer.mdc.picaps.dbaccess.EventTable.resultToObject(EventTable.java:24)
            at com.dartcontainer.mdc.picaps.dbaccess.AbstractTable.resultToObject(AbstractTable.java:239)
            at com.dartcontainer.mdc.picaps.dbaccess.EventTable.resultToObject(EventTable.java:24)
            at com.dartcontainer.mdc.picaps.dbaccess.AbstractTable.resultToList(AbstractTable.java:88)
            at com.dartcontainer.mdc.picaps.dbaccess.EventTable.getEvents(EventTable.java:194)
            at com.dartcontainer.mdc.picaps.dbaccess.EventSetPersister.archiveEventsBetween(EventSetPersister.java:149)
            - locked <0x464d73b0> (a com.dartcontainer.mdc.picaps.dbaccess.EventSetPersister)
            at com.dartcontainer.mdc.picaps.dbaccess.EventSetPersister.archiveEvents(EventSetPersister.java:113)
            at com.dartcontainer.mdc.picaps.dbaccess.EventSetPersister.run(EventSetPersister.java:81)
            at java.util.TimerThread.mainLoop(Timer.java:432)
            at java.util.TimerThread.run(Timer.java:382)

    The answer you probably don't want to hear, is buy yourself a good profiler.
    (e.g. www.jprofiler.com)
    Or at least download it and test it during the trial. I'll at least get you through this.
    You can profile threads to see what monitor they are waiting on, who has it currently, etc.
    Something I like to do is create seperate (inner) classes for each monitor instance I use.
    e.g. class IoLock1 extends Object{} IoLock1 lock1 = new IoLock1();This makes things more clear in the profiler which shows the class of the monitor in question.

  • Jdev freeze while waiting for "something"

    Hi All,
    I have problem in my jdeveloper. everytime when i open my jsp file (contains ADF component) and it is freeze and when i look at the thread information, it is waiting for my internal db connection. If i try to comment out, it is fine but when i am going to deploy, i have to dis-comment my db connection. After that, i open another jsp file, the problem comes out again even i have comment out my db connection after deployment.
    thx for reply and here is the thread information:
    Full thread dump Java HotSpot(TM) Client VM (1.5.0_05-b05 mixed mode):
    "Designer-Layout-Dispatcher" prio=7 tid=0x2e561028 nid=0x2cc in Object.wait() [0x3dfef000..0x3dfef9e4]
    at java.lang.Object.wait(Native Method)
    - waiting on <0x09ca2968> (a oracle.jdevimpl.webapp.view.DisplayManager$RefreshQueue)
    at java.lang.Object.wait(Object.java:474)
    at oracle.jdevimpl.webapp.view.DisplayManager$RefreshDispatcher.run(DisplayManager.java:1436)
    - locked <0x09ca2968> (a oracle.jdevimpl.webapp.view.DisplayManager$RefreshQueue)
    at java.lang.Thread.run(Thread.java:595)
    "Designer-Layout-Dispatcher [file:/C:/Projekts/ViewController/public_html/UserManagement.jsp]" prio=7 tid=0x2e6e75d8 nid=0x5d0 in Object.wait() [0x3c57f000.
    at java.lang.Object.wait(Native Method)
    - waiting on <0x08fa15f8> (a oracle.jdevimpl.webapp.view.DisplayManager$RefreshQueue)
    at java.lang.Object.wait(Object.java:474)
    at oracle.jdevimpl.webapp.view.DisplayManager$RefreshDispatcher.run(DisplayManager.java:1436)
    - locked <0x08fa15f8> (a oracle.jdevimpl.webapp.view.DisplayManager$RefreshQueue)
    at java.lang.Thread.run(Thread.java:595)
    "JSP VE Design Time Thread: ViewController.jpr 1145178935291" prio=7 tid=0x375d0030 nid=0x488 runnable [0x39b7e000..0x39b7f9e4]
    at java.net.Inet4AddressImpl.getHostByAddr(Native Method)
    at java.net.InetAddress$1.getHostByAddr(InetAddress.java:842)
    at java.net.InetAddress.getHostFromNameService(InetAddress.java:532)
    at java.net.InetAddress.getHostName(InetAddress.java:475)
    at java.net.InetAddress.getHostName(InetAddress.java:447)
    at java.net.InetSocketAddress.getHostName(InetSocketAddress.java:210)
    at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:341)
    at java.net.Socket.connect(Socket.java:507)
    at java.net.Socket.connect(Socket.java:457)
    at java.net.Socket.<init>(Socket.java:365)
    at java.net.Socket.<init>(Socket.java:178)
    at org.postgresql.core.PGStream.<init>(PGStream.java:60)
    at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:77)
    at org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:65)
    at org.postgresql.jdbc2.AbstractJdbc2Connection.<init>(AbstractJdbc2Connection.java:116)
    at org.postgresql.jdbc3.AbstractJdbc3Connection.<init>(AbstractJdbc3Connection.java:30)
    at org.postgresql.jdbc3.Jdbc3Connection.<init>(Jdbc3Connection.java:24)
    at org.postgresql.Driver.makeConnection(Driver.java:369)
    at org.postgresql.Driver.connect(Driver.java:245)
    at java.sql.DriverManager.getConnection(DriverManager.java:525)
    - locked <0x27504420> (a java.lang.Class)
    at java.sql.DriverManager.getConnection(DriverManager.java:171)
    - locked <0x27504420> (a java.lang.Class)
    at com.oneNetwork.accountingSystem.common.DAO.GeneralDBDAO.getConnection(GeneralDBDAO.java:36)
    at com.oneNetwork.accountingSystem.common.DAO.CountryDAOPostgresql.getCountryList(CountryDAOPostgresql.java:172)
    at com.oneNetwork.accountingSystem.common.valueobjects.basic.CountryVO.getCountriesList(CountryVO.java:78)
    at com.oneNetwork.accountingSystem.webclient.actions.CountryAction.getList(CountryAction.java:24)
    at com.oneNetwork.accountingSystem.webclient.forms.UserRegister.createCountryList(UserRegister.java:189)
    at com.oneNetwork.accountingSystem.webclient.forms.UserRegister.load(UserRegister.java:137)
    at com.oneNetwork.accountingSystem.webclient.forms.UserRegister.<init>(UserRegister.java:103)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
    at oracle.jdevimpl.webapp.design.renderer.utils.RenderUtils.createBean(RenderUtils.java:232)
    at oracle.jdevimpl.webapp.design.renderer.FacesActionRenderer._addManagedBean(FacesActionRenderer.java:1938)
    at oracle.jdevimpl.webapp.design.renderer.FacesActionRenderer._initialize(FacesActionRenderer.java:1911)
    at oracle.jdevimpl.webapp.design.renderer.FacesActionRenderer._initializeFromFacesConfig(FacesActionRenderer.java:1895)
    at oracle.jdevimpl.webapp.design.renderer.FacesActionRenderer.tagInitialize(FacesActionRenderer.java:1079)
    at oracle.jdevimpl.webapp.design.renderer.DesignTimeJspActionRenderer.renderCustomParentNode(DesignTimeJspActionRenderer.java:877)
    at oracle.jdevimpl.webapp.design.renderer.utils.FacesUtils.renderFakeNamespaceContainer(FacesUtils.java:179)
    at oracle.jdevimpl.webapp.design.support.jsp.DesignTimeJspServlet._renderSource(DesignTimeJspServlet.java:183)
    at oracle.jdevimpl.webapp.design.support.jsp.DesignTimeJspServlet.serviceJsp(DesignTimeJspServlet.java:109)
    at oracle.jdevimpl.webapp.design.support.jsp.DesignTimeJspServlet.service(DesignTimeJspServlet.java:73)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
    at oracle.jdevimpl.webapp.design.support.http.DesignTimeServletInfo.service(DesignTimeServletInfo.java:268)
    at oracle.jdevimpl.webapp.design.support.http.DesignTimeRequestDispatcher.dispatch(DesignTimeRequestDispatcher.java:197)
    at oracle.jdevimpl.webapp.design.support.http.DesignTimeRequestDispatcher.forward(DesignTimeRequestDispatcher.java:72)
    at com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:322)
    at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:130)
    at oracle.adfinternal.view.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:157)
    at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
    at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
    at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
    at oracle.jdevimpl.webapp.design.support.http.DesignTimeServletInfo.service(DesignTimeServletInfo.java:268)
    at oracle.jdevimpl.webapp.design.support.http.DesignTimeRequestDispatcher$DesignTimeFilterChain.doFilter(DesignTimeRequestDispatcher.java:315)
    at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._invokeDoFilter(AdfFacesFilterImpl.java:367)
    at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._doFilterImpl(AdfFacesFilterImpl.java:336)
    at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl.doFilter(AdfFacesFilterImpl.java:196)
    at oracle.adf.view.faces.webapp.AdfFacesFilter.doFilter(AdfFacesFilter.java:87)
    at oracle.jdevimpl.webapp.design.support.http.DesignTimeRequestDispatcher$DesignTimeFilterChain.doFilter(DesignTimeRequestDispatcher.java:292)
    at oracle.jdevimpl.webapp.design.support.http.DesignTimeRequestDispatcher.dispatch(DesignTimeRequestDispatcher.java:193)
    at oracle.jdevimpl.webapp.design.support.http.DesignTimeServletContainerContext._service(DesignTimeServletContainerContext.java:611)
    at oracle.jdevimpl.webapp.design.support.http.DesignTimeServletContainerContext.service(DesignTimeServletContainerContext.java:570)
    at oracle.jdevimpl.webapp.design.DesignTimeRenderThread.runImpl(DesignTimeRenderThread.java:264)
    - locked <0x08082168> (a oracle.jdevimpl.webapp.design.DesignTimeRenderThread)
    at oracle.jdevimpl.webapp.design.DesignTimeThread.run(DesignTimeThread.java:147)
    "CssObservreTimer" daemon prio=5 tid=0x376c9878 nid=0x6a4 in Object.wait() [0x39a7f000..0x39a7fa64]
    at java.lang.Object.wait(Native Method)
    - waiting on <0x08082280> (a java.util.TaskQueue)
    at java.lang.Object.wait(Object.java:474)
    at java.util.TimerThread.mainLoop(Timer.java:483)
    - locked <0x08082280> (a java.util.TaskQueue)
    at java.util.TimerThread.run(Timer.java:462)
    "IdeMinPriorityTimer" daemon prio=2 tid=0x375847c8 nid=0x4c4 in Object.wait() [0x3947f000..0x3947fd64]
    at java.lang.Object.wait(Native Method)
    - waiting on <0x07d4c028> (a java.util.TaskQueue)
    at java.lang.Object.wait(Object.java:474)
    at java.util.TimerThread.mainLoop(Timer.java:483)
    - locked <0x07d4c028> (a java.util.TaskQueue)
    at java.util.TimerThread.run(Timer.java:462)
    "AuditExecutor-15" daemon prio=7 tid=0x2e4955c8 nid=0x690 in Object.wait() [0x38c7f000..0x38c7fae4]
    at java.lang.Object.wait(Native Method)
    - waiting on <0x06b15110> (a oracle.javatools.util.SynchronizedQueue)
    at java.lang.Object.wait(Object.java:474)
    at oracle.javatools.util.SynchronizedQueue.remove(SynchronizedQueue.java:61)
    - locked <0x06b15110> (a oracle.javatools.util.SynchronizedQueue)
    at oracle.jdevimpl.audit.util.SwingExecutor.run(SwingExecutor.java:467)
    at java.lang.Thread.run(Thread.java:595)
    "WaitCursorTimer" daemon prio=5 tid=0x2da7f568 nid=0x3d0 in Object.wait() [0x3895f000..0x3895fce4]
    at java.lang.Object.wait(Native Method)
    - waiting on <0x0671c150> (a java.util.TaskQueue)
    at java.lang.Object.wait(Object.java:474)
    at java.util.TimerThread.mainLoop(Timer.java:483)
    - locked <0x0671c150> (a java.util.TaskQueue)
    at java.util.TimerThread.run(Timer.java:462)
    "BufferDomModel background parse thread" daemon prio=2 tid=0x2da7e490 nid=0x654 in Object.wait() [0x3885f000..0x3885fd64]
    at java.lang.Object.wait(Native Method)
    - waiting on <0x06051f88> (a java.util.TaskQueue)
    at java.lang.Object.wait(Object.java:474)
    at java.util.TimerThread.mainLoop(Timer.java:483)
    - locked <0x06051f88> (a java.util.TaskQueue)
    at java.util.TimerThread.run(Timer.java:462)
    "WeakDataReference polling" prio=2 tid=0x368297d0 nid=0x630 in Object.wait() [0x3875f000..0x3875f9e4]
    at java.lang.Object.wait(Native Method)
    at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:116)
    - locked <0x06050ac8> (a java.lang.ref.ReferenceQueue$Lock)
    at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:132)
    at oracle.ide.util.WeakDataReference$Cleaner.run(WeakDataReference.java:88)
    at java.lang.Thread.run(Thread.java:595)
    "Native Directory Watcher" prio=2 tid=0x373618d0 nid=0x4fc runnable [0x3855f000..0x3855fae4]
    at oracle.ide.natives.NativeHandler.enterWatcherThread(Native Method)
    at oracle.ide.natives.NativeHandler$1.run(NativeHandler.java:244)
    at java.lang.Thread.run(Thread.java:595)
    "IconOverlayTracker Timer" prio=5 tid=0x3738f010 nid=0x2f8 in Object.wait() [0x3845f000..0x3845fb64]
    at java.lang.Object.wait(Native Method)
    - waiting on <0x05ffe648> (a java.util.TaskQueue)
    at java.lang.Object.wait(Object.java:474)
    at java.util.TimerThread.mainLoop(Timer.java:483)
    - locked <0x05ffe648> (a java.util.TaskQueue)
    at java.util.TimerThread.run(Timer.java:462)
    "TimerQueue" daemon prio=5 tid=0x2dc17ec0 nid=0x500 in Object.wait() [0x2e3ff000..0x2e3ffd64]
    at java.lang.Object.wait(Native Method)
    - waiting on <0x059a0678> (a javax.swing.TimerQueue)
    at javax.swing.TimerQueue.run(TimerQueue.java:233)
    - locked <0x059a0678> (a javax.swing.TimerQueue)
    at java.lang.Thread.run(Thread.java:595)
    "AWT-EventQueue-0" prio=7 tid=0x2dbec780 nid=0x458 in Object.wait() [0x2e28e000..0x2e28f9e4]
    at java.lang.Object.wait(Native Method)
    - waiting on <0x08082168> (a oracle.jdevimpl.webapp.design.DesignTimeRenderThread)
    at java.lang.Object.wait(Object.java:474)
    at oracle.jdevimpl.webapp.design.DesignTimeRenderThread.service(DesignTimeRenderThread.java:141)
    - locked <0x08082168> (a oracle.jdevimpl.webapp.design.DesignTimeRenderThread)
    at oracle.jdevimpl.webapp.design.DesignTimeEngine.service(DesignTimeEngine.java:346)
    at oracle.jdevimpl.webapp.design.view.DesignTimeViewDocument._serviceJsp(DesignTimeViewDocument.java:930)
    at oracle.jdevimpl.webapp.design.view.DesignTimeViewDocument.rebuildTree(DesignTimeViewDocument.java:206)
    at oracle.jdevimpl.webapp.design.view.DesignTimeFixedViewDocument.rebuildTree(DesignTimeFixedViewDocument.java:155)
    at oracle.jdevimpl.webapp.model.content.dom.view.proxy.ProxyViewDocument.initialize(ProxyViewDocument.java:80)
    at oracle.jdevimpl.webapp.editor.AbstractWebAppEditor.rebuildViewDocument(AbstractWebAppEditor.java:686)
    at oracle.jdevimpl.webapp.editor.html.HtmlEditor.rebuildViewDocument(HtmlEditor.java:621)
    at oracle.jdevimpl.webapp.editor.jsp.JspEditor.rebuildViewDocument(JspEditor.java:209)
    at oracle.jdevimpl.webapp.editor.AbstractWebAppEditor.createDocuments(AbstractWebAppEditor.java:1206)
    at oracle.jdevimpl.webapp.editor.AbstractWebAppEditor.open(AbstractWebAppEditor.java:393)
    at oracle.jdevimpl.webapp.editor.html.HtmlEditor.open(HtmlEditor.java:172)
    at oracle.jdevimpl.webapp.editor.jsp.JspEditor.open(JspEditor.java:113)
    at oracle.ideimpl.editor.EditorState.openEditor(EditorState.java:239)
    at oracle.ideimpl.editor.EditorState.createEditor(EditorState.java:147)
    at oracle.ideimpl.editor.EditorState.getOrCreateEditor(EditorState.java:90)
    at oracle.ideimpl.editor.SplitPaneState.canSetEditorStatePos(SplitPaneState.java:231)
    at oracle.ideimpl.editor.SplitPaneState.setCurrentEditorStatePos(SplitPaneState.java:194)
    at oracle.ideimpl.editor.TabGroupState.createSplitPaneState(TabGroupState.java:103)
    at oracle.ideimpl.editor.TabGroup.addTabGroupState(TabGroup.java:275)
    at oracle.ideimpl.editor.EditorManagerImpl.createEditor(EditorManagerImpl.java:1261)
    at oracle.ideimpl.editor.EditorManagerImpl.createEditor(EditorManagerImpl.java:1196)
    at oracle.ideimpl.editor.EditorManagerImpl.openEditor(EditorManagerImpl.java:1131)
    at oracle.ideimpl.editor.EditorManagerImpl.whenOpenEditor(EditorManagerImpl.java:2332)
    at oracle.ideimpl.editor.EditorManagerImpl.handleDefaultAction(EditorManagerImpl.java:1893)
    at oracle.ide.controller.ContextMenu.fireDefaultAction(ContextMenu.java:343)
    - locked <0x05b615b0> (a java.util.ArrayList)
    at oracle.ideimpl.explorer.BaseTreeExplorer.fireDefaultAction(BaseTreeExplorer.java:1504)
    at oracle.ideimpl.explorer.BaseTreeExplorer.dblClicked(BaseTreeExplorer.java:1841)
    at oracle.ideimpl.explorer.BaseTreeExplorer.mouseReleased(BaseTreeExplorer.java:1862)
    at oracle.ideimpl.explorer.CustomTree.processMouseEvent(CustomTree.java:176)
    at java.awt.Component.processEvent(Component.java:5253)
    at java.awt.Container.processEvent(Container.java:1966)
    at java.awt.Component.dispatchEventImpl(Component.java:3955)
    at java.awt.Container.dispatchEventImpl(Container.java:2024)
    at java.awt.Component.dispatchEvent(Component.java:3803)
    at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4212)
    at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3892)
    at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3822)
    at java.awt.Container.dispatchEventImpl(Container.java:2010)
    at java.awt.Window.dispatchEventImpl(Window.java:1774)
    at java.awt.Component.dispatchEvent(Component.java:3803)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
    at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:242)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
    "Java2D Disposer" daemon prio=5 tid=0x2db98d40 nid=0x54c in Object.wait() [0x2e08f000..0x2e08fae4]
    at java.lang.Object.wait(Native Method)
    at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:116)
    - locked <0x05986308> (a java.lang.ref.ReferenceQueue$Lock)
    at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:132)
    at sun.java2d.Disposer.run(Disposer.java:107)
    at java.lang.Thread.run(Thread.java:595)
    "AWT-Windows" daemon prio=7 tid=0x2db7c5e0 nid=0x650 runnable [0x2df8f000..0x2df8fb64]
    at sun.awt.windows.WToolkit.eventLoop(Native Method)
    at sun.awt.windows.WToolkit.run(WToolkit.java:269)
    at java.lang.Thread.run(Thread.java:595)
    "AWT-Shutdown" prio=5 tid=0x2dbd2268 nid=0x3a0 in Object.wait() [0x2de8f000..0x2de8fbe4]
    at java.lang.Object.wait(Native Method)
    - waiting on <0x059863f0> (a java.lang.Object)
    at java.lang.Object.wait(Object.java:474)
    at sun.awt.AWTAutoShutdown.run(AWTAutoShutdown.java:259)
    - locked <0x059863f0> (a java.lang.Object)
    at java.lang.Thread.run(Thread.java:595)
    "Low Memory Detector" daemon prio=5 tid=0x01119d10 nid=0x67c runnable [0x00000000..0x00000000]
    "CompilerThread0" daemon prio=5 tid=0x01118600 nid=0x5b8 waiting on condition [0x00000000..0x2d95fa48]
    "Signal Dispatcher" daemon prio=5 tid=0x010f94d8 nid=0x160 waiting on condition [0x00000000..0x00000000]
    "Finalizer" daemon prio=8 tid=0x010eb008 nid=0x680 in Object.wait() [0x2d75f000..0x2d75fae4]
    at java.lang.Object.wait(Native Method)
    at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:116)
    - locked <0x0592aa40> (a java.lang.ref.ReferenceQueue$Lock)
    at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:132)
    at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:159)
    "Reference Handler" daemon prio=5 tid=0x007afc20 nid=0x5fc in Object.wait() [0x2d65f000..0x2d65fa64]
    at java.lang.Object.wait(Native Method)
    at java.lang.Object.wait(Object.java:474)
    at java.lang.ref.Reference$ReferenceHandler.run(Reference.java:116)
    - locked <0x0592aac0> (a java.lang.ref.Reference$Lock)
    "main" prio=5 tid=0x007a9b18 nid=0x69c waiting on condition [0x00000000..0x0012fb60]
    "VM Thread" prio=5 tid=0x010e8ae8 nid=0x644 runnable
    "VM Periodic Task Thread" prio=5 tid=0x0112cc00 nid=0x550 waiting on condition
    NAV _ ENTITY TYPE :: End Customer

    I was just going to suggest these two solutions myself. If you've got the time, check into this stuff.
    1) use Thread.join() to wait (block) until a given
    Thread completes its task.
    2) Bite the bullet and learn how to use
    wait()/notify() (Google should send you to some good
    tutorials). Granted, it can be a complex topic, but
    it is vital to know if you want to write efficient
    asynchronous programs.
    Good luck!

  • How to do custom dialog so it displays the dialog and waits for user to end

    I have an application that I want to create my own dialog screens. For example, the user cliks on one frame, and I want to open a window for the user to enter data, after the user finishes, he presses OK and then the main app continues.
    On the class that I open the dialog, I open it with:
    NewOkCancelDialog.abrePopup();
    System.out.println("Program should wait for the dialog to close");And the 'NewOkCancelDialog' class is defined like:
    public class NewOkCancelDialog extends javax.swing.JDialog {
    The constructor is like:
    public NewOkCancelDialog(java.awt.Frame parent, boolean modal) {
    super(parent, true);
    initComponents();
    this.setLocation(400,400);
    This methods are when the user activates the button and the popup closes..
    private void cierraPopupOk(){
    resultados.setciudad1(this.fld_ciudad1.getText());
    if (resultados.getciudad1length() < 3) {
    System.out.println("Error en la entrada!");
    } else {
    doClose(RET_OK);
    private void okButtonActionPerformed(java.awt.event.ActionEvent evt) {                                        
    cierraPopupOk();
    private void doClose(int retStatus) {
    returnStatus = retStatus;
    this.estaAbierto = false;
    setVisible(false);
    dispose();
    I would like to have the application in the first lines, after calling
    NewOkCancelDialog.abrePopup();
    to wait until the method doClose() in NewOkCancelDialog class is finnished. But right now, after the ...abrePopup() is called, it continues.
    What am I doing wrong? or what am I not doing?

    Use the "code" tags not the "bold" tags when posting code.
    But right now, after the ...abrePopup() is called, it continues.Well your posted code doesn't show this method so we don't know what you are doing in this method.
    Why are you using a static method to show the dialog? Normally the code would be:
    JDialog dialog = new CustomDialog();
    dialog.setVisible( true );
    But you are correct with the basic idea in that you need to use a modal dialog.

  • Aerender error: "Unable to execute script at line 95. Window does not have a constructor"

    A BG Renderer user is getting this error when running aerender version 10.5.1x2:
    "Unable to execute script at line 95. Window does not have a constructor"
    The render proceeds but the process never completes which is preventing the rest of the BG Renderer notifications from triggering.  Any idea what this error means and how to fix it?
    Thanks,
    Lloyd

    I guess we'll have to wait for Adobe to answer what could be causing the transmission to drop on Line 95. Todd's out of the office for a month or two, but maybe someone else can shed some light.

  • Sleep or wait() / notify()  Which is better IYO

    Consider an app where a central object, like an information server is handed a query and an amount of time will pass before that information is available. For caching, many objects may ask the same question and be waiting on the same answer. Is it better to have the queries do a sleep loop to wait for the response or is it better for the queries to register with the server and call a wait(), then have the server issue a notify to objects that were waiting?
    Thanks for the advice.

    Thank you. I like sleep as well. Although with three little ones that can be a difficulty.
    I am having a difficulty with how to implement the wait notify. Can you tell me if the following is a good / bad / normal / horribly wrong example?
    // sorta code...
    // This class goes to a central location
    // or the network for an answer.  It represents one answer for one query.
    class InfoServerQuery extends Thread{
      volatile boolean isComplete = false;
      volatile String response = null;
      Vector pool = new Vector();
      public synchronized boolean isReady(Object obj){
        if(!isComplete){
          // Add object to answer pool
          pool.add(obj);
          return false;
        }else{
          return true;
      public void run(){
        try{
          // Get the information.......
          response = getInfo();
          // set isComplete
          isComplete = true;
          // notify all that are waiting.
          for(int a = 0; a < pool.size(); a++)
          synchronized(pool.get(a)){pool.get(a).notify();};
        }catch(Exception e){
          throw new RuntimeException();
    // This class asks the questions.
    class QueryClient{
      // instantiated in constructor
      InfoServerQuery q;
      public String getAnswer() throws Exception{
        while(!q.isReady(this)) synchronized(this){wait();};
        return q.response;
    }Thanks for any insights.

Maybe you are looking for

  • How do I fix my Macbook Pro (2010)?

    I have a 2010 Macbook Pro that I was getting ready to sell. My screen had the wobble and I went to fix it. For some reason, when I put it all back together... the Mac will not boot correctly. 1.) There is no display 2.) It boots once and makes a driv

  • Startup disk question/problem

    Should the startup disk always be at the top of the list of disks upon startup? Or is it now the case, with 10.5 on a MacBook, that the internal disk is at the top of the list whether or not it is the startup disk? Situation: New MacBook Mac OS 10.5.

  • Reg:error messages display in wdabap

    hi expert could you please say what i need to pass the values which are mandatory in this error message coding .can you please share some the documents related to error messages display. method ONACTIONEXECUTEACTION . if sy-subrc ne 0 . get message m

  • How do I resolve Error 1017 that I'm getting during build application?

    When I'm building my application for labview RT to put on my PXI controller I get Error 1017.  How do I resolve this error?

  • Tabs that are open when I close, won't reopen when I restart FF

    Using FF 20.0.1 All of a sudden, today/yesterday, when I reopen FF, the tabs that were there when I closed are not there anymore----the only tab open is my homepage...... Yes, I do have "show my tabs from last time when I open FF" checked. What's up?