hexagon logo

Executing Cable or Other Wizard Dialog Through CMD Language?

I've got a fairly complex cable system that I've set up in the Cable Wizard and saved as a .wzd file. Sometimes my model configuration will change drastically as a design evolves so I prefer to build everything from modular CMD files as opposed to interactively in the gui.
 
How can I load in this .wzd file and execute the Cable Wizard again through CMD language?
 
  • Hi Michael,
    Best solution is to search on SimCompanion for a valid example:
     
    short story:
    adamsXXXX_X aview ru-standard b MODEL_NAME.cmd ex
    where XXXX_X is the release of choice 2020_1, 2024_1 ...
     
    thanks,
  • @Alexis Del Rio​ 
    Hi Alexis, I'm specifically asking how I can import the cable .wzd configuration file and execute just the cable wizard dialog through a series of commands in my existing cmd file (as opposed to having to click through the gui menus).
     
  • Hi Michael,
    I guess you could write a cmd-script that would step through the wizard. (interface push_button execute ...)
    For the specific task of reading in the .wzd file you would have to look at what the commands are behind that import push button, and execute these commands yourself. Look it up through the database navigator and see what commands are behind it.
  • @Henrik Skovbjerg​ 
    I've done a bit of digging and for some reason the I can't seem to figure out the commands that this .wzd load button is running when I push it and select the file.
    Wizard
    image
    Things I've tried:
    1) looking at CMD window output when executing the button. No relevant commands appear
    2) Snooping in the cable wizard dialog box code (interface dialog box modify). For some reason I can't seem to select the buttons on the bottom of this wizard dialog. I can access pretty much every other gui element in the cable wizard (.amachinery.wizards.cable_wiz) and view its underlying commands but that load button is not selectable.
    3) database navigator doesn't seem to reveal any buttons for loading the .wzd file in the cable wizard gui.
    image
    Any thoughts on where else to look?
  • Hi Michael,
    I had a deeper look into the wizards, and it seems that these are not controllable through the command language (which in my mind is very bad Adams-practice). I did not find any way to automate wizard handling.
     
    If your cable system is changed by moving things around (not adding or removing pulleys) or changing parameters for the cable system, then you might get away with modifying these parameters directly and maybe executing a "ude modify instance" command on the element these belong to.
     
    Example:
    I could modify the cable diameter directly by modifying the corresponding design variable under the cable_cable element.
    Moving a pulley was done by moving the marker it was sitting on, and then afterwards doing "ude modify instance" on the specific cable_pulley element.
    You will have to be careful and check that everything is updated correctly.
     
  • Thanks for checking, that's too bad. I like the wizard file format since its fairly simple XML and it seems like it would be easy to update or swap to different configurations. I'll try to extract the commands after it builds the system and try the ude modify route for adjusting things.