Jump to content

Peter Vandewalle

Distributor
  • Posts

    319
  • Joined

  • Last visited

Posts posted by Peter Vandewalle

  1. Also check on the hatch definitions.

    Often users scale dwg's after import because of wrong unit conversion during import. Units are almost always wrong in dwg files.

    If you scale the dwg after import, hatch definitions won't scale along. This results in thousands or even millions of hatch lines that need to be calculated when zooming or panning. Of course this slows down the file.

    Check all hatch definitions with a name in capitals.

  2. On 1/12/2024 at 6:34 PM, E|FA said:

    What are the chances of the tool being available to users of other versions (e.g. USA)?

    Years ago, we proposed the tool to the other distributors worldwide. The answer was that Vectorworks users (architects) never make these drawings. So they were not interested.

    In Belgium, architects do make those plans.

    • Like 1
  3. I think it is a combination of the 4th and the 5th letter that determines the country and language. And then again a serial number for a localised version will also run an english version while the serial for an english version won't allow you to open a localised version.

    If you need to know the language of the software, you'd better use the GetCurrentLocalization( VAR language  :STRING; VAR subLanguage  :STRING) call. It'll return you a code like ENG, NLD, FRA, PLN, ...

    • Like 1
  4. In Python that'll be

    Import <path to file>
     

    The file path starts from the plug-in folder and doesn't need the .py extension.

     

    In most cases I use this script in the Vectorworks editor:

     

    import <path>.main as mod

    mod.main()

    The <path> just points to a folder in the plugin folder.
    The path folder contains 3 files:

    __init__.py

    main.py

    code.py

     

    The init file is needed to make the folder work as a Python module. It's just an empty text file names __init__.py

     

    The main.py file contains:


    def main():
        import <path>.code as mod
        from importlib import reload
        reload(mod)
        mod.main()

     

    The code.py file contains a def called main that contains the actual code.

     

     

    • Like 1
  5. A script could indeed make the object list for the criteria. In that case you'd have every wall code just once with all its component underneath. Depending on the data you'd like to extract that could work.

    If you'd need to i.e. count the number of walls for each code, that would need an additional script to calculate the results.

  6. @Pat Stanford I happened to encounter the same issue last week. I had a training for 2 users from the same company. 1 uses an English version, the other uses a Dutch version. I explained the advantages of workgroup folders until I encountered the language issue.

    Library folders have different names depending on the language. So when one user creates the workgroup folder, the sub folders like "Library/Defaults" are created. When the other user adds the same workgroup folder, another subfolder "Bibliothèque/Ressources" (for French) is created.

    This results in library objects that can't be shared between different languages versions.

    Finally I had to make both users use the same language version (English). Which is a shame since the French version holds more tools and localized libraries than the international English version. Users with a French (or Dutch) serial number can run English versions but not vice versa.

  7. I'm trying to get a handle to a selected object in a wall.

     

    When I select a PIO object in a wall (in this case a pilaster) and I run this script:

    def apply_code_to_objects(hObj):
        vs.AlrtDialog(f"Obj: {vs.GetTypeN(hObj)} in {vs.GetTypeN(vs.GetParent(hObj))}")
    
    
    vs.ForEachObject(apply_code_to_objects, "(INSYMBOL & INOBJECT & NOTINDLVP & NOTINREFDLVP & (VSEL=TRUE))")

    I get "Obj: 68 in 31", where 68 is wall and 31 is a design layer.

     

    I can't find a way to get a handle to the selected pilaster though...

     

    Any ideas?

  8. I guess @Hamois a Mac user, just like me. Mac users had the Mac OS color system for years. The Windows color system has always been far less complete. Now Vectorworks gave all the Mac OS color system advantages to the Windows users also. Mac users didn't loose anything, they just need to change some of their habits.

×
×
  • Create New...