Notifications
Clear all

[Closed] make dir

I created simple maxscript installer but I stuck in one place.
I have to create folder under 3dsmax (program files) to store all sub-files in one place which are necessary for my main script to work .
I though the best place for this would be “plugins” directory, so I decide to create my own dir like “C:\Program Files\Autodesk\3ds Max 2013\plugins\my_plugin” but it seems there is access denied to create any folder under “C:\Program Files”. I write this plugins also for other people so I`m confused how to access folder under programfiles or maybe there is better place to store plugins for 3dsmax.

code:
max_folder=(GetDir #maxroot)
makeDir (max_folder +”\plugins”+”\my_plugin”) all:true

or

DOSCommand (“mkdir ” +max_folder+”\plugins”+”\my_plugin”)

3 Replies

Use this folder:

#userscripts

You will have full access to it – can create sub-folders, copy and delete files and folders, etc.
I use it in all of my installers and there are no problems at all.

 JHN

Agreed, it’s bad design to have your folders/files in a program files directory, it’s officially disproved my microsoft and any serious IT person will put program files behind restricted access.

Like miauu said:
Go with getDir #userscripts and getDir #userconfig etc.
It also solves the problem when you want someone with a design version of max to use your script or even a older/newer version of max.

-Johan

but some scripts have to go into specific folders within the max directory to work correctly and quite a few third party extensions create subfolders within max to keep stuff organized.