fileoutputstream Questions
5
Solved
Is there a way to get the file name from a FileOutputStream or from FileInputStream?
Stradivari asked 8/2, 2011 at 6:7
2
Solved
Saving the file:
FileOutputStream fo = null;
try {
fo = this.openFileOutput("test.png", Context.MODE_WORLD_READABLE);
} catch (FileNotFoundException e) {
e.printStackTrace();
}
bitmap.comp...
Juno asked 2/8, 2010 at 14:51
4
Solved
It's perfectly described here how to do it, the only problem: He doesnt know the function openFileOutput();
private void saveSettingsFile() {
String FILENAME = "settings";
String string = "hello...
Infective asked 2/9, 2010 at 14:23
1
This is a function I have written that tries to:
Create a folder with the users name
Save a .jpg inside of that
folder
The folder creation works fine, however when I try to save the pictures...
Alroi asked 28/4, 2016 at 13:49
1
So I have an app on Google Glass that takes a picture, then converts it to grayscale and overwrites the original image in memory:
private void rGBProcessing (final String picturePath, Mat image) {...
Magnetograph asked 22/2, 2015 at 17:55
3
Solved
Can someone explain me why this construction wont work:
while (fileInputStream.available()>0) {
fileOutputStream.write(fileInputStream.read());
}
and this one works just fine:
while (file...
Euphonize asked 6/10, 2015 at 12:49
2
Solved
I created a file using FileOutputStream and it is an excel file (using HSSF Liberary)
FileOutputStream fileOut = new FileOutputStream(text+".xls");
then I write what I need in my excel file (wo...
Procurable asked 20/9, 2015 at 8:47
2
Solved
I'm really confused about flush and close method.In my code I always close my FileOutputStream object. But I want to know that if I have to use flush method here, and where can I use it?
I will wr...
Smew asked 16/7, 2015 at 14:10
2
Solved
I have an app that saves into a file (internal storage) data input by the user and at startup it loads this file and shows the contents. I would like to know: where can I find my file (data.txt)?
I...
Salita asked 7/1, 2015 at 12:2
2
Hi i am trying to read excel from assets and wanted to convert it into JSON, But i am getting the error: open failed:ENOENT(No such file or directory), searched many SO questions but could not find...
Approbate asked 25/11, 2014 at 7:13
1
Solved
I'm using Volley as my network stack in a project I'm working on in Android. Part of my requirements is to download potentially very large files and save them on the file system.
Ive been looking ...
Doble asked 23/10, 2014 at 7:29
1
Solved
Original code and its working saving the data to the SD Card
// Writing data to internal storage
btnSaveData.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v...
Laboy asked 13/10, 2014 at 9:22
3
Solved
What I'm trying to do is this: I want my application to download an image from the Internet and save it to the phone's internal memory in a location that is private to the application. If there is ...
Heteroecious asked 15/11, 2010 at 5:9
1
Solved
I am trying to add an object( of OneChatMessage class) into a file on every button click. And then i try to read all the objects from the file and load it into a ArrayList. But i get a Stream...
Pinnati asked 27/5, 2014 at 12:30
1
Solved
I have a function to compress a file and another to decompress it. When I try to decompress an archive I've generated with my own function, there is a null pointer exception because it doesn't foun...
Glossotomy asked 12/12, 2013 at 10:26
2
Solved
I want to write in a file and then read from it. While using openFileOutput(..,..) method I get that this method is not defined as it is an abstract method. Then I tried it with passing the context...
Bolger asked 28/8, 2012 at 10:12
5
Solved
I'm developing for the Android platform.
My app creates a temp file with a simple call to:
FileOutputStream fos = openFileOutput("MY_TEMP.TXT", Mode);
It works fine because I can write to it and...
Perimorph asked 20/7, 2010 at 14:53
1
Solved
I am trying to rotate a pdf 180 degrees and I am using the ITextSharp library to do so. The code below is taken from their site's examples. However, I can't seem to find the right namespace to impo...
Guiltless asked 25/7, 2013 at 18:53
2
Solved
I am using Java to write a byte array to a file. When I open my file in a hex editor I am not always seeing the bytes that I expected to be there. Here is my example code and contents of the output...
Moersch asked 14/6, 2013 at 7:17
0
I am trying to implement the function where i can start and stop the video recording multiple times, and accumulate video data into a File.
This is how i prepare my media recorder:
private boolea...
Axletree asked 29/1, 2013 at 9:33
4
Solved
I am confused about this.
Since when doing implementation of Serializable class, we need to use classes like FileOutputStream, ObjectOutputStream or something like that. Then why not we just use th...
Kaylil asked 25/7, 2012 at 15:33
2
Solved
I am trying to save some block coverage using an array of integers that simply saves the number of times a block is executed. For some reason, though, when I try and write to some files that I crea...
Ciceronian asked 23/7, 2012 at 21:17
3
Solved
I have this strange thing with input and output streams, whitch I just can't understand.
I use inputstream to read properties file from resources like this:
Properties prop = new Properties();
Inp...
Clavicembalo asked 8/5, 2012 at 4:48
2
Solved
I have an API call that returns a byte array. I currently stream the result into a byte array then make sure the checksums match and then write the ByteArrayOutputStream to File. The code is someth...
Mcniel asked 28/3, 2012 at 15:23
1
Solved
After getting no answer to my last question, I reformulated the thing to its simplest form. 1 button, 1 clicklistener, 1 serializable object and 1 subroutine to output the serializable object. This...
Aldon asked 17/3, 2012 at 5:8
© 2022 - 2024 — McMap. All rights reserved.