How to write a file with directory ?

by sunwrt » Fri, 17 Apr 2009 16:26:35 GMT


Sponsored Links
 Hi,Guys,

I  wrote a file to the sdcard, but it failed as follow:

   String sdcardFIle = "/sdcard/xxx.txt"
   FileOutputStream fos = openFileOutput(sdcardFile,
Context.MODE_WORLD_WRITABLE);

openFileOutput failed, because fIle  "/sdcard/xxx.txt" contains a path
seperator.

It is so strange. Is there  another way to handle the situation ???

Thanks in advance
--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. Low Memory: No more background processes.

Hi,

I am working on openGles with seven images displayed on the screen. I
am translating the position of these seven images on a button click so
it is drawing every time it seems.
But, after sometime all the images are getting disappeared then I've
checked in the logcat
I found this :ctivityManager(52): Low Memory: No more background
processes.

Could someone please post the solution to this problem?


Thanks,
Bala

--~--~---------~--~----~------------~-------~--~----~

2. ADC2 Challenge

Hi,

I am aware that this challenge is only open to Apps or developers who
have not published their apps on the Android Market before 1st
August.

But my question is this:

a) What is stopping a developer from just changing the name of his/her
app or renaming the app package? Surely others will try this?
b) Are there any developers here that created apps in anticipation for
the ADC2 to only find that by publishing on the Android Market, you
will lose out on the eligibility clause?

Cheers,

Vaz

--~--~---------~--~----~------------~-------~--~----~

3. CTS fails for java.io.OutputStreamWriterTest

4. About App names in ADC and Market

5. text view focus

6. Emulator does not show up when using self-build kernel

7. Emulator does not show up when using self-build kernel