A realll quicky with files
Author |
Message |
tlivingston
|
Posted: Thu May 13, 2004 6:30 pm Post subject: A realll quicky with files |
|
|
K how do i make it so that when i write/ read from a file, it will find the file in the same place as where teh class is saved?
Eg Instead of ==> FileReader fin = new FileReader("c://highScore.txt");
==> FileReader fin = new FileReader("place where class is saved//highScore.txt");
Thanks,
Ted |
|
|
|
|
![](images/spacer.gif) |
Sponsor Sponsor
![Sponsor Sponsor](templates/subSilver/images/ranks/stars_rank5.gif)
|
|
![](images/spacer.gif) |
rizzix
|
Posted: Thu May 13, 2004 7:42 pm Post subject: (No subject) |
|
|
use relative paths. |
|
|
|
|
![](images/spacer.gif) |
tlivingston
|
Posted: Thu May 13, 2004 9:36 pm Post subject: (No subject) |
|
|
i have no idea what that means....lol...so like what do i put instead of c:\\highScore.txt?
Thanks,
Ted |
|
|
|
|
![](images/spacer.gif) |
rizzix
|
Posted: Thu May 13, 2004 11:05 pm Post subject: (No subject) |
|
|
"highscore.txt" or "./highscore.txt" its all relative |
|
|
|
|
![](images/spacer.gif) |
|
|