obj export in MaxfilePath

710 Views Asked by At

I can't english well:(
I made funtions FBX Exporter and OBJ Exporter.


fn FBXexport =
(
    local MaxSave = getFilenamePath maxfilename + "\\" + getFilenameFile maxfilename + ".fbx"
    local plug = findItem exporterPlugin.classes FBXEXP

   exportFile MaxSave #noPrompt selectedOnly: (selection.count != 0 ) using: plug
)


fn OBJexport =
(
    local MaxSave = getFilenamePath maxfilename + "\\" + getFilenameFile maxfilename + ".obj"
    local plug = findItem exporterPlugin.classes ObjExp

    exportFile MaxSave #noPrompt selectedOnly: (selection.count != 0 ) using: plug
)

it is same code to getFilenamePath.

FBX Exporter is success to MaxfilePath\MaxfileName.fbx
but OBJ Exporter made OBJ, Maxfile in Drive\MaxfileName.obj ( E:\Maxfilename.obj )

I don't know why :(
I want to make obj in maxfilePath

1

There are 1 best solutions below

0
On

I fixed it.

fn OBJexport = 
    (
        local MaxSave = getFilenamePath maxfilepath + "\\" + getFilenameFile maxfilename + ".obj"
        local plug = findItem exporterPlugin.classes ObjExp

        exportFile MaxSave #noPrompt selectedOnly: (selection.count != 0 ) using: plug
    )