Jump to content

Vsevolod

Member
  • Content Count

    2
  • Joined

  • Last visited

Community Reputation

0 Neutral

About Vsevolod

  • Rank
    Greenhorn

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Vsevolod

    Get data from a Worksheet with Python script?

    Yes, I've checked your code and it runs exactly as you said and what I'm searching for! Thanks, Raymond!
  2. I've been trying to get data from a worksheet by Python script. Here is the basic code: def FindTable(): hLayer = vs.GetParent( vs.FObject() ) vs.EnableDrawingWorksheetPalette(True, None) while hLayer != None: h = vs.FInLayer( hLayer ) while h != None: # worksheet? if vs.GetTypeN(h) == 56: rows, cols = vs.GetWSRowColumnCount(h) cellnum = vs.GetCellStr(h,1,1) vs.AlrtDialog( vs.Concat('Cell 1 ',cellnum,' Name: ',vs.GetName(h),' visible: ',vs.AreWorksheetGridLinesVisible(h),' rows=', rows, ' cols=', cols) ) h = vs.NextObj( h ) hLayer = vs.NextLayer( hLayer ) return 0 It doesn't work and returns 0 rows and columns. I guess "Worksheet container" type is not good and these APIs don't work but the cycle returns only handle with type 56 even without any 'if' condition. Maybe "Worksheet" type is what I'm looking for? types and IDs But how can I obtain it?

 

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.

×