Creating a new shelf through Mel

By using $gShelfTopLevel I can get to the parent layout of the shelf; however, without using the normal call to create a Shelf, createNewShelf, I cannot figure out how to add new shelf.

I'm an idiot...

global string $gShelfTopLevel;
shelfLayout -p $gShelfTopLevel "the new shelf name";

Mo

The only problem with this so far is that I cannot access the shelf editor after creating the new shelf. It seams to be missing some sort of setup calls that make it final.

Anyone have an idea?

From: Dobson, Jeff [mailto:jdobson@soe.sony.com]
Sent: Wednesday, September 03, 2003 5:45 AM
To: 'maya@highend3d.com'
Subject: RE: Creating a new shelf with Mel...

Have you looked at the built-in command/script addNewShelfTab? I always use that because it is as simple as...

addNewShelfTab Char_shelf;

If you don't want the black-box approach to using the script, dig up the script in scriptsothers and it should have all the hints you need for doing this.

--JeffD