Jump to content

PatW

Member
  • Posts

    65
  • Joined

Everything posted by PatW

  1. Just stumbled over the vs-py rosetta stone, in case you dont already know it: https://developer.vectorworks.net/index.php/User:CBM-c-/VS-Py_Rosetta_Stone
  2. The trouble is caused by the special character in node "Info/Bemerkung" remove the "/". The error message was hard to understand.
  3. When I want to see the implementation of a SDK function I always need to open the cpp file by the explorer like "..VW2023_WIN64\SDKLib\Source\VWSDK\VWFC\Tools\ProgressDlg.cpp". Does any one know the trick to jump directly with visual studio to the source like you can do on the local cpp files? I tried it with adding the directory to "VC++ Source Directories" and "Additional Include Directories" but that didn't help. regards, Patrick
  4. I think it would be more easy to save the most recent created handle + timestamp as static parameters. If the move event is within a specific time after the create ignore it.
  5. This should do it: https://developer.vectorworks.net/index.php/VS:IsObjectFlipped regards, Patrick
  6. have you tried importing it withgout the .py ending:
  7. I used to create a "update" script in the resource palette for this. Import all modules that should be updated within there and execute it when changes have been made before running the real script.
  8. It means apply rotation before applying the offset. Addition: Rotations use always the 0,0,0 as anchor. Whne you want to rotate some object about his own axis you would have to move it first with the axis on 0,0,0 then rotate and move it back where it was. This step is saved by the RotateBefore function. regards, Patrick
  9. You can also directly check "if ! h" the handle class has the boolean method implemented. regards, Patrick
  10. PythonBeginContext; PythonExecute( 'import os' ); PythonExecute( 'os.remove( r"C:\Users\admin\Desktop\remove.txt")' ); PythonEndContext; This should do it. Make sure the file is in a dir where VW has the permission to delete it. regards, Patrick
  11. PatW

    Truss Pickups

    1. Import the sym from my attached drawing, replace existing 2. Select the hoist where this symbol is used and select the pickup in the OIP as when you set it up the first time, this provokes a refresh. Be sure to select the local pick up symbol from the file and not the one from the libe. regards, Patrick
  12. PatW

    Truss Pickups

    Attached is the modified symbol that fits to the truss. Please replace it in your file and then reselect it in the Hoist OIP "Select PickUp Symbol..." regards, Patrick 24PinTrussPick.vwx
  13. PatW

    Truss Pickups

    You can change the "Low Hook To load Trim" value in the "Geometry" section, this will change the pick up position without changing the hoists Z position. Can you share this file. regards, Patrick
  14. Wem sagst du das 😄 Off yourse this is not desired behaviuor, but at least you can use the alternative key shortcut it until the bug is fixed. I will push this foreward.
  15. I guess your are using a quertz keyborad and remember that there was an issue doing the undo with this. Try it with Ctrl-Y 😉 Tell me if that works.
  16. Replace the MOve code by this. If it is a param obj it will use SetEntityMatrix.
  17. Try the node "Set Entity Matrix". regards, Patrick
  18. I see nothing wrong, also the example has this issue. https://developer.vectorworks.net/index.php/VS:PythonExecute As a workaround i would add the whitespace and always check if the first letter is a whitespace (in case the problem gets fixed). If the first letter is a whitespace you have to remove it again. regards, Patrick
  19. 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.
  20. GetBBox Take a look at https://developer.vectorworks.net/index.php/VS:Function_Reference#Object_Info Maybe HWidth, HLength is better in your case.
  21. 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.
  22. I was having a look. In the case off the "Truss Record" the values are saved as strings with the unit.
  23. 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
  24. 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
×
×
  • Create New...