hi all
how i can read from text file please send to me the code

I see this little class called a "FileReader", it sounds like something you could use.

this little class "FileReader" not found to me although import java.io.* because my tool is NetBeans 5.0 mobility(mobile application)

usama: hi all
how i can read from text file please send to me the code

try {
        BufferedReader in = new BufferedReader(new FileReader([COLOR=#0066ff][I]"inputfilename"[/I][/COLOR]));
        String str;
        while ((str = in.readLine()) != null) {
            [COLOR=#0066ff][I]/*Add your code to process the string*/[/I][/COLOR]
        }
        in.close();
    } catch (IOException e) {
    }
Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.18 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.