[mono-android] Antwort: Re: Deleting files on external storage?

BernhardGessler at cs-ag.de BernhardGessler at cs-ag.de
Tue Mar 29 10:30:26 EDT 2011


Me too.




"Carlo Bolz" <cb at dm-edv.de> 
Gesendet von: monodroid-bounces at lists.ximian.com
29.03.2011 16:22
Bitte antworten an
monodroid at lists.ximian.com


An
<monodroid at lists.ximian.com>
Kopie

Thema
Re: [mono-android] Deleting files on external storage?






I am experienced the same behaviour – but can´t resolve it.
 
Regards,
Carlo
 
Von: monodroid-bounces at lists.ximian.com 
[mailto:monodroid-bounces at lists.ximian.com] Im Auftrag von Jon Valvatne
Gesendet: Dienstag, 29. März 2011 11:07
An: Jb Evain
Cc: monodroid at lists.ximian.com
Betreff: Re: [mono-android] Deleting files on external storage?
 
Oops - looks like I created a too-simple test case. This also fails in the 
same way, though:
 
                System.IO.FileStream fs = 
System.IO.File.Create("/sdcard/test.txt");
                fs.Close();
                System.IO.File.Delete("/sdcard/test.txt"); 
 
On Tue, Mar 29, 2011 at 11:00 AM, Jb Evain <jbevain at gmail.com> wrote:
Hi,

On Tue, Mar 29, 2011 at 10:51 AM, Jon Valvatne <jon at norsync.com> wrote:
>                 System.IO.File.Create("/sdcard/test.txt");
>                 System.IO.File.Delete("/sdcard/test.txt");
>
> Has anyone successfully deleted a file off external storage from C# 
code?
Have you properly disposed the created file stream (using either the
Close or Dispose method, or the using pattern on it) before trying to
delete the actual file?

Jb
 _______________________________________________
Monodroid mailing list
Monodroid at lists.ximian.com

UNSUBSCRIBE INFORMATION:
http://lists.ximian.com/mailman/listinfo/monodroid


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/mailman/private/monodroid/attachments/20110329/8b2defd8/attachment-0001.html 


More information about the Monodroid mailing list