No. But you don't need to!
I need... open the panel from script.
Well, as I said, no that can't be done.
But (as I also said) you don't NEED to! You can change all properties of a style directly with a script.
I think Leonardo is tired of going to a particular submenu of a paragraph style, and that he wants a script to open it for him. It's possible that you can do that with app.menu or app.menuAction, but I've no experience with those at all.
Yeah that's what I thought as well, but it won't work because you cannot set the 'active' (selected) style in the panel. Right?
I'm thinking he's thinking he needs to open the dialog to change a property of an existing style.
I'm thinking that what you're thinking that he's thinking is not entirely correct. You are correct in that you don't need to open the dialog to change anything there, but I think that he doesn't want to change anything by script (probably because he thinks he can't do that) -- he just wants one of us to do a script that opens the Paragraph Style Options dialog.
It looks as though you were right, by the way. This:
// the "Style Options" item in the par. st. panel
produces this error: "The requested action opened an asynchronous previewable modal dialog. This is not compatible with the scripting architecture, and so the dialog has been automatically dismissed using the default button."
But maybe we should wait and see what Leonardo really thinks!
I am back with few more minutes and a more detailed answer..
Let's say at a certain point in the script, I'd have to open the user dialog, to let the user (eventually) modify the script, when some caracteristics aren't matching.
So I was trying a way to open the normal dialog, like with a mouse double click on the name of the style, but as you saw, it doesn't look working..
Not an english native.. and I posted while I was really in a hurry.. sorry!
I haven't come up with a way of doing this.
If someone has figured out a way, I'm all ears as well...
Hey Gabe.. if you too haven't.... probably isn't possible I guess..
Do you really need the user to be able to change *all* properties?
If not and it's just a small list, you could make sort of your own style edit dialog, containing just the items that the user can change.
Yes.. probably I'll follow that way..
But it is a pity.. all is done already!!! ehehehe...