Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > text file accessing in Applet

Reply
Thread Tools

text file accessing in Applet

 
 
vidhi
Guest
Posts: n/a
 
      01-30-2006
i have an applet application which runns by useing values avilable in a
text file, as per the situation it rung great.
but the problem occures when multiple instance of applet over a network
is running and try to access the text file at same instance, in this
situation only one applet can have access the file and rest are hang up
at line which uses the file, one the applet file which have file access
grant will close then next but only one at this time also get the
access to that file.
i thought i might be sharing vocation problem.
here is the code what i use to access.

BufferedReader br=new BufferedReader(new
InputStreamReader(getClass().getResourceAsStream(" MyTextFile.txt")));
try
{
while((str=br.readLine())!= null)
{
strRange=br.readLine();
}
}catch(IOException io){}

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Accessing JAR file specified in APPLET tag's "archive" attribute Sajjad Lateef Java 3 06-19-2012 12:52 PM
text file accessing in Applet vidhi Java 1 01-30-2006 08:49 PM
Java applet failed when I try to load the avi file in my java applet Krista Java 3 09-15-2004 02:53 AM
Re: play wave files using java.applet.Applet webster Java 0 07-20-2003 01:51 PM
applet vs. canvas in applet Rob Love Java 1 07-07-2003 10:07 PM



Advertisments