Jump to content
Martin Crawford

Worksheets in Python

Recommended Posts

Is it possible to place a worksheet in a drawing, do you do this similar to a placing a symbol?

 

Thanks 

 

Martin

Share this post


Link to post

http://developer.vectorworks.net/index.php/VS:Function_Reference#Worksheets

http://developer.vectorworks.net/index.php/VS:CreateWSImage

def vs.CreateWSImage(worksheet, location):
    return HANDLE

from the Dev Wiki.

 

location is 2DPoint location on the drawing.

 

eg:

ws_name = "Worksheet-1" # this is an example, replace with name of your worksheet you want placed on your drawing

ws_def_handle = vs.GetObject(ws_name) # grab a handle to the worksheet definition in your resource manager
location = (0,0) # places center of drawing
ws_handle_on_dwg = vs.CreateWSImage(ws_handle, location)

 

Share this post


Link to post

Thanks.

 

I saw the function, however I thought is was dealing with images and not the worksheet. I should spend more time clicking.

 

Thanks

 

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

 

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.

×