![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Aug 2005
Posts: 1
Rep Power: 0
![]() |
reading in a file in java
How exactly can I go about reading in a file in java? I know how to do in C so that I can just drag the file onto the binary of the program and whatnot, but my knowledge of java is limited at best.
Basically what I am trying to do is write a little program to manipulate a txt file that I drag on to the java program. |
|
|
|
|
|
#2 |
|
Hobbyist Programmer
Join Date: Jun 2005
Location: MA, US
Posts: 204
Rep Power: 4
![]() |
http://www.mathcs.carleton.edu/facul...3/iocheat.html
for more information on the classes used there, check out: http://java.sun.com/j2se/1.5.0/docs/api/
__________________
"A stupid man's report of what a clever man says can never be accurate, because he unconciously translates what he hears into something he can understand." - B. Russell http://web.bryant.edu/~srk2 |
|
|
|
|
|
#3 |
|
Newbie
Join Date: Aug 2005
Posts: 2
Rep Power: 0
![]() |
Use java.io package.
If ur interested in some sample examples let me know |
|
|
|
|
|
#4 |
|
Newbie
Join Date: Jun 2005
Posts: 16
Rep Power: 0
![]() |
String sFileName = c_sFilePath + c_sFileName;
File fFile = new File(sFileName); |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|