Follow along with the video below to see how to install our site as a web app on your home screen.
Anmerkung: This feature may not be available in some browsers.
RandomAccessFile raf = new RandomAccessFile(file, "rw");
while ((line_header = raf.readLine()) != null){
if(linecount >= 0) {
linecount--;
} else {
/*hier die zeile in datei speichern*/
/*so sieht eine zeile aus:*/
/*88.000000 23.457031 20.263672 23.701172 21.240234 22.724609 21.240234 22.480469*/
raf.writeBytes(line_header);
}
/*File auswählen*/
file = jFileChooser.getSelectedFile();
String line = null;
String line_measurement = null;
int linecount = 30;
try {
RandomAccessFile raf = new RandomAccessFile(file, "r");
while((line = raf.readLine()) != null) {
if(linecount >= 0) {
linecount--;
} else {
if(line_measurement != ""){
line_measurement = line_measurement + "\n" + line;
} else {
line_measurement = line;
}
}
}
FileOutputStream fos = null;
try {
fos = new FileOutputStream(file);
fos.write(line_measurement.getBytes());
} catch(IOException se) {
} finally {
try {
fos.close();
} catch(IOException e2) {
}
}
} catch(IOException ioe) { /*do nothing*/
}