ZBrushCentral

How to pass arguments to button presses?

'Nother simple (but not yet to me) question, sorry. I’m attempting to have a texture load automatically; that is, I already know the file path to the texture, and want it to load without the user needing to select it in a dialog. However, [IPress, Texture:Import] will obviously bring up such a dialog. The docs I have for IPress don’t show any way to pass in an argument to a button press. Is such a thing possible?

There’s gotta be some way to do this :slight_smile:

Thanks,
Ken

Use FileNameSetNext.

Marcus is too fast for me these days:D

When importing/loading all you need is the FileNameSetNext command as Marcus said. But when exporting/saving you may need a little extra if you want no user interaction.

If the file already exists the “do you want to overwrite?” dialog pops up. Simply insert the IPress command into a IKeyPress command to handle the dialog window.


[FileNameSetNext, "ZBRUSH_ZexportImport/Temp.psd"]
[IKeyPress, 13, [IPress, Texture:Export]] // 13 is the ascii code for the enter key