Jump to content

twk

Member
  • Content Count

    511
  • Joined

  • Last visited

Community Reputation

143 Spectacular

5 Followers

About twk

  • Rank
    500 Club

Personal Information

  • Occupation
    Architectural Designer
  • Homepage
    www.cba-design.co.nz
  • Location
    Auckland, New Zealand

Recent Profile Visitors

2,016 profile views
  1. twk

    Updating Record from Excel Spreadsheet

    I've never been able to get this to work, do you have a short step-by-step description of how you've gotthen the ODBC to work? -- edit -- BTW, I use to the openpyxl python module to talk between vectorworks and excel. If only there were better documentation on the external databases connection process for VW Cheers, Tui
  2. twk

    Until Next Time

    Wow... was not expecting this at all!?... Vectorworks' loss for sure! In any case, you have set the standard for customer/user support for any company. All the best in your future endeavors!
  3. If you're looking for viewport class visibilities, they're under the 'Group' category in the DevWiki. http://developer.vectorworks.net/index.php/Category:VS_Function_Reference:Objects_-_Groups They have viewport layer visibility getters and setters there as well. Cheers, Tui
  4. twk

    List All Classes in file

    Heres another one that lists them all in one text object, adding the option to show the stacking order number with it or not. -- Save your work before using -- get_layer_type = lambda x:vs.GetObjectVariableInt(x, 154) # 1 = Design Layer, 2 = Sheet Layer, 3 = Referenced Layer get_layer_type_switch = 0 #Custom switch, change to get different layer types 0=Design Layers Only, 1=Sheet Layers Only, 2=Both Design Layers and Sheet Layers show_stacking_order = False #Set to True if you want the string to show the stacking order number beside it font_size = 10 layer_names = [] hLayer = vs.FLayer() while hLayer != None: layer_type = get_layer_type(hLayer) if get_layer_type_switch == 0: if layer_type == 1: layer_names.append(vs.GetLName(hLayer)) elif get_layer_type_switch == 1: if layer_type == 2: layer_names.append(vs.GetLName(hLayer)) elif get_layer_type_switch == 2: layer_names.append(vs.GetLName(hLayer)) hLayer = vs.NextLayer(hLayer) # we now reverse sort the layer_names list. For some reason this method retrieves layers in reverse order of the stack shown in the Navigation Pallette. layer_names.reverse() text_str = "\r".join([str(x) for x in layer_names]) if show_stacking_order: text_str = "\r".join(["[{}] {}".format(i, x) for i,x in enumerate(layer_names)]) vs.CreateText(text_str) TEXT = vs.LNewObj() vs.SetTextVerticalAlign(TEXT,3) vs.SetTextJust(TEXT, 1) vs.SetTextSize(TEXT, 0, len(vs.GetText(TEXT)), font_size)
  5. twk

    List All Classes in file

    Swap out integers for the get_layer_type_switch, to retrieve a list of either Design Layers, Sheet Layers or Both. -- Save your work before using -- get_layer_type = lambda x:vs.GetObjectVariableInt(x, 154) # 1 = Design Layer, 2 = Sheet Layer, 3 = Referenced Layer get_layer_type_switch = 0 #Custom switch, change to get different layer types 0=Design Layers Only, 1=Sheet Layers Only, 2=Both Design Layers and Sheet Layers layer_scale = vs.GetLScale(vs.ActLayer()) # page mm scale 1:1 spacing = 3 * layer_scale font_size = 10 layer_names = [] hLayer = vs.FLayer() while hLayer != None: layer_type = get_layer_type(hLayer) if get_layer_type_switch == 0: if layer_type == 1: layer_names.append(vs.GetLName(hLayer)) elif get_layer_type_switch == 1: if layer_type == 2: layer_names.append(vs.GetLName(hLayer)) elif get_layer_type_switch == 2: layer_names.append(vs.GetLName(hLayer)) hLayer = vs.NextLayer(hLayer) # we now reverse sort the layer_names list. For some reason this method retrieves layers in reverse order of the stack shown in the Navigation Pallette. layer_names.reverse() text_objects = [] for layer_name in layer_names: vs.CreateText(layer_name) TEXT = vs.LNewObj() # set text vertical align and horizontal align = center, left vs.SetTextVerticalAlign(TEXT, 3) vs.SetTextJust(TEXT, 1) vs.SetTextSize(TEXT, 0, len(layer_name), font_size) text_objects.append(TEXT) for i, text in enumerate(text_objects): if i != 0: prev_text = text_objects[i-1] prev_text_bbox = vs.GetBBox(prev_text) vs.HMove(text,0,(prev_text_bbox[1][1])-spacing)
  6. twk

    Database CAPITALS

    Hi @John Meunier, Looks like a glitch in the matrix.. - Any other formula added to that glitching cell doesn't work. - If I copy the formula out, then replace it with the cell's formula next to it. The worksheet starts to function again. - Now I can copy back in the first formula I had (or you wrote), and it recalculates fine. 2019-03-14_13-24-08.mp4
  7. twk

    Database CAPITALS

    There is no native way to do it. But you could with a script. 1. Create a script in your file name it 'WS_ALL_CAPS' . (When it asks you to create a palette, just name the palette whatever you want, something like 'WS Scripts' will suffice. 2. When the script dialog box pops up, change the language to Python. 3. Use the code below in your script: orignal_str = vs.WSScript_GetPrmStr(0) vs.WSScript_SetResStr(orignal_str.upper()) 4. Now back in your worksheet, select the cell you want capitalized. Enter this into the formula bar: =RUNSCRIPT('WS_ALL_CAPS', 'Existing Tree'.'ActionComment') 5. Recalculate Active Worksheet
  8. twk

    Railing/Fence Tool

    Just as a follow up to my previous post being for a 3rd party Addon to Archicad, the actual native Handrail tool in Archicad is something to be envious of as well..
  9. Pretty amazing what these guys are doing. https://twitter.com/Test_Fit_io
  10. I remember seeing the 2016 Marionette video about cladding walls.. looked so promising, until I tried it myself. Short answer : a short endeavor..
  11. twk

    Vectorworks to Twinmotion

    Oh you definatley should check out @JRA-Vectorworks-CAD's work. Youtube channel here: https://www.youtube.com/channel/UC56qp6QeXSAayDOOHu3BcCA
  12. twk

    VW beginner is stuck

    After extruding a circle, you can user-adjust position of top or bottom end of cylinder by activating the "ReShape" Tool command. (highlighted tool in screenshot below)
  13. Wondering how 2019 does it with titleblock data being able to read TB info from another file? Could not find any related functions for opening one file in another file in the DevWiki or the SDK files.
  14. Greetings and happy new year all, I was wondering if there was anyway to access plugin data from a file other than the active one? Wanting to read in data from a plugin object that resides in another file. Cheers, Tui
  15. twk

    The Vectorworks Twitch

    This I can relate to.. on the other hand, surley Teamviewer sessions with Vectorworks Tech support would be much faster/cheaper/easier then bug submissions/phone calls/site visits? I should probably wishlist this..

 

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.

×