ScriptSpot home

Forum topic · General Scripting

Drop Downs

By John Pester · 2013-03-25

Description

Hi There

Im very new to Max Script and am looking for some help

Im trying to create a UI and im needing to make various shapes using a drop down list.
Basically i want to select an object from the drop down list and it will make it in max.
This is what ive got so far:
try (destroydialog test_button) catch ()

rollout test_button "Reset Max"
(

button theButton "Reset Max"---Creates Button

on theButton pressed do---When pressing Button
resetMaxFile #noprompt---Resets Max File

dropdownlist scale_dd "Shape:" items:#("Box", "Plane", "Pyramid", "Cone")
on scale_dd selected i do
format "You selected '%'!\n" scale_dd.items[i]---???????????????
)

createDialog test_button 500 300

Will be grateful for any help

Thanks

Comments (5)
John Pester

Also is there a way to select that created object afterwards???

miauu

This is one of the ways you can use.


on scale_dd selected i do
(
	execute (scale_dd.selected + "()")
)
Reply to miauu
John Pester

Also is there a way to select that created object afterwards???

Reply to miauu
Branko Živković

;)


execute (scale_dd.selected + " isSelected:on")