Get your CodeRanch badge!*
The moose likes Servlets and the fly likes portList.hasMoreElements() in Java and Servlets Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "portList.hasMoreElements() in Java and Servlets" Watch "portList.hasMoreElements() in Java and Servlets" New topic
Author

portList.hasMoreElements() in Java and Servlets

g venki
Greenhorn

Joined: Mar 08, 2010
Posts: 8
HI Everyone

I am writing a SerialPort communication code in Servlets....

I had already executed the code in java.

The statement "System.out.println(":::"+portList.hasMoreElements());" in java is printing as TRUE

and

The statement "out.println(":::"+portList.hasMoreElements());" in Servlets is printing as FALSE

Both are executed on the same system one followed by other.
Can anyone tell me what is the reason for this?
Devaka Cooray
ExamLab Creator
Saloon Keeper

Joined: Jul 29, 2008
Posts: 2885
    
  13

Please KeepItDown


Author of ExamLab ExamLab - a free SCJP / OCPJP exam simulator
My Home Page -- Twitter Profile -- JavaRanch FAQ -- How to Ask a Question
g venki
Greenhorn

Joined: Mar 08, 2010
Posts: 8
Devaka Cooray wrote:Please KeepItDown


I am sorry . I dont know about that.

Any ways my problem is resolved.

Thank You
g venki
Greenhorn

Joined: Mar 08, 2010
Posts: 8
We have to place the javax.comm.propeties in jre/lib directory
 
jQuery in Action, 2nd edition
 
subject: portList.hasMoreElements() in Java and Servlets
 
Similar Threads
How does one control the order in which methods are executed?
Exception handling in Junit
Doubt in try and finally block execution.
How to stop the execuation of jsp flow
Adding objects to the list