Jump to content
  • 0

Marionette to python script


Rob87

Question

Hi Folks,

 

I build a working marionette and exported it as python file (Rightclick on marionette node -> Save Marionette Script as Python Script -> Saved File on local drive).

Then I made a new Python script and imported the File into it (in Script Editor -> Text File)

 

Now I get this error message:

1004367613_Bildschirmfoto2022-09-27um11_35_12.thumb.png.b65f534f65e48e0f6683258ed4fd952a.png

 

I know, there is a way to implement the marionette as a menu command. But this is not what I want. I want the script to be included in the file.

 

Can somebody help please?

 

Thanks!

 

Regards,

Rob

Inst Type Popup.vwx

Link to comment

3 answers to this question

Recommended Posts

  • 0

Thanks Pat,

 

I'm familiar with this procedure. The problem is  that we have lots of users and more and more marionettes up to come. The creation of the menu commands has to be done by every user. I already know that there will be some voices complaining about this workaround. I know, the menu commands are saved to a vwx file. I also could share this file with the users, but for me the best way would be to have it saved in the file itself. Then it will be only one file to updated and not two. And because this file is in s cloud storage, it updates for every user automatically. 

 

A script executing a marionette would also be perfect! Is this possible?

 

Thanks!

Link to comment
  • 0

I have done some testing and it appears you are correct that the Marionette Menu Commands are only stored in a specific file in the User folder.

 

Path to user folder here/Vectorworks/2023/Libraries/Defaults/Marionette/Marionette Command Library.vwx

 

I have submitted an enhancement request to have Marionette Menu Commands behave like most other defaults and be able to use any file name in the correct path in the User, Workgroup, or Application Folder too store the commands.

 

In the mean time, if you don't have tom many people (preferably only one) who is making menu commands, at least on the Mac I was able to create a Hard Link (a normal alias file was not enough) to a file stored in a shared location in the User folder and VW would see that.  

 

By using a link you would only have to set it up once for each user. When you make changes to the shared file the next time each user restarts VW, they will get any changes you have made.

 

The down side is that if multiple people are making Menu Commands, there is a possibility of file corruption.

 

Best work around I can come up with for now.

  • Like 2
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...