hey ty for the fast reply
but i tried and it does not work
here is my code:
btnSave.setOnClickListener(new View.OnClickListener() {
public void onClick(View v) {
s = tv1.getText().toString();
s2 = ET1.getText().toString();
try { File root =
Environment.getExternalStorageDirectory();
if (root.canWrite()){
File gpxfile = new File(root,s2+".txt");
FileWriter gpxwriter = new FileWriter(gpxfile);
BufferedWriter out = new
BufferedWriter(gpxwriter);
out.write(s);
out.close();
Toast.makeText(Test.this, "your file has been
saved",
Toast.LENGTH_SHORT).show();
}}
catch (Exception e) {
Toast.makeText(Test.this, e+"",
Toast.LENGTH_SHORT).show();
}
sendBroadcast(new Intent(Intent.ACTION_MEDIA_MOUNTED,
Uri.parse("file://"+
Environment.getExternalStorageDirectory())));
Intent myIntent = new Intent(((View)
v).getContext(),Menu.class);
startActivityForResult(myIntent, 1);
}
});
On May 31, 2:09 pm, vandana toshniwal <[email protected]>
wrote:
> sendBroadcast(new Intent(Intent.ACTION_MEDIA_MOUNTED,
> Uri.parse("file://"+ Environment.getExternalStorageDirectory())));
>
> On 31 May 2010 11:21, jp <[email protected]> wrote:
>
>
>
> > Hi vandana toshniwal
>
> > thank for the fast reply. Do u have a example how to use
> > ACTION_MEDIA_MOUNTED and specify the
> > SDCARD path ?
>
> > On May 31, 12:13 pm, vandana toshniwal <[email protected]>
> > wrote:
> >> hi
>
> >> just send a broadcast with action ACTION_MEDIA_MOUNTED and specify the
> >> SDCARD path
>
> >> Regards
>
> >> Vandana Toshniwal
>
> >> On 31 May 2010 09:28, jp <[email protected]> wrote:
>
> >> > is there a way to refesh sdcard without turning off the phone?
>
> >> > --
> >> > You received this message because you are subscribed to the Google
> >> > Groups "Android Developers" group.
> >> > To post to this group, send email to [email protected]
> >> > To unsubscribe from this group, send email to
> >> > [email protected]
> >> > For more options, visit this group at
> >> >http://groups.google.com/group/android-developers?hl=en-Hide quoted text -
>
> >> - Show quoted text -
>
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Android Developers" group.
> > To post to this group, send email to [email protected]
> > To unsubscribe from this group, send email to
> > [email protected]
> > For more options, visit this group at
> >http://groups.google.com/group/android-developers?hl=en- Hide quoted text -
>
> - Show quoted text -
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en