Hi All ....
I am trying to edit a file using RandomAccessFil e.
I am having a little bit problem.
My file is ...
[code=java]
RandomAccessFil e file = new RandomAccessFil e("file_name"," rw");
file.seek(10);
file.write("aaa aaaaaaaaaaaaaaa aaaaaaaaaaaaaaa a".getBytes( ));
[/code]
My edited file is ....
Where as I expected as .......
Please help me.
I can do this by saving the last file content.
But I want this by using a simple API.
Debasis Jana.
I am trying to edit a file using RandomAccessFil e.
I am having a little bit problem.
My file is ...
Code:
i m debasis jana.
RandomAccessFil e file = new RandomAccessFil e("file_name"," rw");
file.seek(10);
file.write("aaa aaaaaaaaaaaaaaa aaaaaaaaaaaaaaa a".getBytes( ));
[/code]
My edited file is ....
Code:
i m debasaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
Code:
i m debasaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaais jana.
I can do this by saving the last file content.
But I want this by using a simple API.
Debasis Jana.
Comment