Exemplo n.º 1
0
        public static bool deleteDir(Java.IO.File dir)
        {
            if (dir != null && dir.IsDirectory)
                {
                    string[] children = dir.List();
                    for (int i = 0; i < children.Length; i++)
                    {
                        bool success = deleteDir(new Java.IO.File(dir, children[i]));
                        if (!success)
                        {
                            return false;
                        }
                    }
                }

            return dir.Delete();
        }