Browse folder
Hey ! How are you ? :)
Look I've this :
files = getFiles "C:\Users\seven\Documents\3dsmax\FBX\*.max"
I want to create a dialog to looking for the directory I want.
for exemple
My_file => looking for my repertory in a dialog files = getFiles My_file
How can I do this ?
Thanks for your help
Comments
The problem is that variable
The problem is that variable allFIles that holds all .max files from the selected folder is not "visible" when you press the btn_export. To fix this:
Tools and Scripts for Autodesk 3dsMax
Works perfect
Thanks !!!! it work perfect !
but what mean ?
allFIles is variable.It can
allFIles is variable.It can be a number(integer or float), a string, name,bitarray,array,etc.
local means tha this variable is visible only for the script and when you close the rollout the variable is deleted fromthe memory.
getFiles returns all files in the given directory as array, so
with:
i define the allFiles to an array
In maxscript this
#()
means array and can contains almost whateveryou want.
Tthis
#{}
means bitarray().
Check the maxscript help file formore detailed explenations:
- Scope of variables
- array
- bitarray
When you define a variable in the
on btn_ pressed do
(
)
this variable can't be accessed in another event handle, so if you want to access a variable everywaher in the rollout you have to define it as local before any event handles or as a global(check Scope of variables in the maxscript helpfile).
Tools and Scripts for Autodesk 3dsMax
Idon't have max right now(I
Idon't have max right now(I am at work) but:
Tools and Scripts for Autodesk 3dsMax
Thx
Thanks you but I can't find what is false in my script with your browse dialog :s