Jump to content

PatW

Member
  • Content Count

    46
  • Joined

Community Reputation

14 Good

1 Follower

About PatW

  • Rank
    Greenhorn

Personal Information

  • Location
    Germany

Recent Profile Visitors

951 profile views
  1. VectorScripts always have to be triggered by the user you can not listen for events in the background. That would be possible with the C++ SDK. If you want to communicate with OAuth by a menu command, it should be possible with python.
  2. GetBBox Take a look at https://developer.vectorworks.net/index.php/VS:Function_Reference#Object_Info Maybe HWidth, HLength is better in your case.
  3. I found it practical to use a "Pass" node in a shiny color for comments. But better try to split the network in many capsulated wrappers that describe themself with their name, so you keep it cleaner and don't need to maintain the comments.
  4. I was having a look. In the case off the "Truss Record" the values are saved as strings with the unit.
  5. Hi tbexn, use the Trussitem parametric record for the length, I don't know how python gives you the value, but all Dimensions fields save their value as millimeter internally, the UI like ObjectInfoPalette then automatically converts it. Secondly for HP made up of individual symbols (so no truss record) is there a way to get either the symbols total length or the even more directly the HPs total length? I would use the bounding box off the geometry in the symbol definition. Don't use the BoundingBox off the HangingPosition because it will not be accurate if the HP or profile is rotated (inside the HP). regards, Patrick
  6. Hi Andreas, For rounding the string use the placeholder {:+.2f} This placeholder combines 2 fromating types. See doc: https://www.w3schools.com/python/ref_string_format.asp Input: sFormat: "The Formated number is {:+.2f}" sArg: 9.99 outPut: "The Formated number is +10.00" regards, Patrick
  7. No problem: valve_example_v2021b210_v2019.vwx
  8. Hi Marau, attached is a little example off the valve node that lets you run code optionally. valve_example.vwx
  9. 1. For every symbol defined in the resource manager there is one Symbol Definition (grouplike object that contains the actual objects) that can have multiple Symol Instances in the drawing. You collected the symbol instances. To get the definition you have to get the name first: 1.1 So to get the symbol off a lightning device you get the symbol instance inside the parametric object (grouplike object). In the doc is a good example off iterating groups: https://developer.vectorworks.net/index.php/VS:FInGroup 2. To find param objects by a creatia you have to look if the parametric record is present which is mostly eual to the name in the OIP:
  10. Vs errors are basically prints and no real exceptions, no way to catch them. For what reason do you need developer mode enebaled then? If it's just to show some prints you can put a link to the output on your desktop and disable dev mode: C:\Users\admin\AppData\Roaming\Nemetschek\Vectorworks\2020\ErrorOut.txt
  11. Check in the script editor(top right) that PPython is the selected Language I supsect you have VectorScript selected. regards, Patrick
  12. You could populate a recordfield with all the string (comma seperated) and acces it from outside. regards, Patrick
  13. PatW

    Explode

    Hi Chansson, it was intended to work like this, but I just noticed that "Get Gravity Center" is returning 0 always for groups. Take a look at the Marionette Object examples where the group is the control geometry.
  14. What does the error say?
  15. Seems like VW does not offer a function but you could try this hack: - Convert the line into a temp. Solid (extrude along path) - Intersect it with the other solid: http://developer.vectorworks.net/index.php/VS:IntersectSolid By the error you should be able to tell if the objects intersect. regards, Patrick

 

7150 Riverwood Drive, Columbia, Maryland 21046, USA   |   Contact Us:   410-290-5114

 

© 2018 Vectorworks, Inc. All Rights Reserved. Vectorworks, Inc. is part of the Nemetschek Group.

×
×
  • Create New...