batch exporter-help wanted !


I got a scene with many objets.I need to export each of them individualy in W3D with the name they got in the scene.
(exemple: box1, box2 of the scene will do box1.w3d and box2.w3d)

I only found a script that batch export with the max file name
and I don’t speak any words from the planet maxscipt !<://
waiting for your good advices !



try this:

outputPath = getSavePath “Save to:”
if (outputPath != undefined) do for obj in objects do exportFile (outputPath + “\” + + “.w3d”) #noPrompt


It seam to not work ://
here’s where I am:
this work. I unhide object one by one and i just press the “créer un W3d” and its ok!!
Now, I’d like to automate the process that it export each object in the scene alone!

utility massexport “FOREGE Xporter”
bitmap logo filename:“forege.bmp”
button doit “créer un W3d”
on doit pressed do
filename = getopenfilename types:“MAX(.max)|.max”
max hide inv --hide unselected obj

	--objName =
	for ob in selection do
		objName =
		exportfile ((getfilenamepath filename) + (objName) + ".w3d") #noPrompt



oh, sorry, i just forgot that exportFile exports the complete scene, so you should put a ‘Select ob’ before the exportFile in your loop and add the parameter ‘selectedOnly:TRUE’ to the exportFile command. this should do it, and then there is no need to hide/unhide the objects anymore… i hope i haven’t overseen something else :wink:


just tested this, seems to work correctly…

outputpath = getSavePath “Save to:”

if (outputPath != undefined) do
objList = getCurrentSelection()
for o=1 to objList.count do
exportName = outputPath + “\” + objList[o].name + “.w3d”
select objList[o]
exportfile exportName #noPrompt selectedOnly:TRUE


This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.