Hi friends,
I have some problem, i need delete folder but not have code in maxscript for this.
:(
PS: they had understood? my english is very very bad😳
Forum topic · General Scripting
By Aline3D · 2007-02-28
Hi friends,
I have some problem, i need delete folder but not have code in maxscript for this.
:(
PS: they had understood? my english is very very bad😳
Comments (5)
Comment policy
HiddenDOSCommand
Lets not forget the HiddenDOSCommand which runs in the background. No annoying flash on your screen.
folder deletion
Even neater, try the dotnet method:
fileClass = dotNetClass "System.IO.Directory"
fileClass.Delete @"c:\directoryName" true
true sets the deletion to recursive so you delete all the files and subfolders
simples...
ei.
fn deleteFolder folderPath: =
(
local sioDir = dotNetClass "System.IO.Directory"
if (SIODir.Exists folderPath) do SIODir.Delete (folderPath) true
)
--example
deleteFolder folderPath:"c:\\temp\\TestFolder"
You could try the DOSCommand()
Something like this:
DOSCommand "rd c:\\theFolder"
Don't forget to use a double \\ in the path name because the command is a filename string
wowww.. very tanks friend 😉
this is!!
AlineLima
Script Developer - SeagullsFly
www.seagullsfly.com
Brazil