Welcome to Telelogic Product Support
  Home Downloads Knowledgebase Case Tracking Licensing Help Telelogic Passport
Telelogic System Architect (steve huntington)
Decrease font size
Increase font size
Topic Title: Getting properties of Objects
Topic Summary: System properties
Created On: 23-Aug-2006 21:25
Status: Read Only
Linear : Threading : Single : Branch
Search Topic Search Topic
Topic Tools Topic Tools
Subscribe to this topic Subscribe to this topic
E-mail this topic to someone. E-mail this topic
Bookmark this topic Bookmark this topic
View similar topics View similar topics
View topic in raw text format. Print this topic.
 23-Aug-2006 21:25
User is offline View Users Profile Print this message


Matt Sheranko

Posts: 82
Joined: 7-Oct-2005

I am trying to get the properties of an object.  The object in particular is a definition. 

myObject.GetProperty("TypeName") returns nothing.
myObject.TypeName returns "Application"  Like it should.

Why doesn't myObject.GetProperty("TypeName") work too?

It does appear to work for myObject.GetProperty("Name")

See attached code sample below.  Is there any what to make TypeName and ddid properties of an object visible to GetProperty method for an object if it is a Definition, Symbol or Diagram?

-------------------------
Thanks,

MattS
Report this to a Moderator Report this to a Moderator
 23-Aug-2006 23:07
User is offline View Users Profile Print this message


Duane Hennessy

Posts: 112
Joined: 18-May-2006

Cool. First let me say I'm impressed you are using line numbers. I don't see too much of it these days

Anyhoo...
Can you get the answer you want from the Symbol.TypeName method instead.

Another way to get the TypeName of a definition is to create a lookup table of TypeNames and run a query. In the attached code is the help text I copied on how to create a Type Lookup Table. Then you could get the SAType or ddid and do a lookup.

You could also create a class that holds all of the SATypes within it and have methods that return the TypeName for the SAType passed in.

Why do you want the definition TypeName?

Report this to a Moderator Report this to a Moderator
 24-Aug-2006 14:13
User is offline View Users Profile Print this message


Matt Sheranko

Posts: 82
Joined: 7-Oct-2005

Duane

Thanks for the reply.  You are easy to impress, I need the line numbers for error checking because I have so many errors!

I wanted to get object.typeName, object.ddid etc so I could write a change history XML doc to both object.myHistoryProperty and an Access database etc.  I currently use VBA to get updates to my architecture from an Access db.  Users update an excel spreadsheet, I then iterate through rows, getObjectsByKey, update changes in SA, and create a change history record then persist this change history XML doc to my Access DB and the updated object in SA.  Probably overkill, but a good change history saves the day when users identify inconsistent data etc.

I like your direct access to database in general, but wanted to explore the VBA interface and SA Object model.  Once I have a good understanding of that, it will be easier to figure out how the SA Object Model is implemented in the backend DB.
fficeffice" />>


Thanks for the additional insight to how the db handles type etc.  Was that from the published SA Help files?



-------------------------
Thanks,

MattS

Edited: 24-Aug-2006 at 14:17 by Matt Sheranko
Report this to a Moderator Report this to a Moderator
 25-Aug-2006 01:42
User is offline View Users Profile Print this message


Duane Hennessy

Posts: 112
Joined: 18-May-2006

Some from the help, some from experience and the rest guesstimate.
Report this to a Moderator Report this to a Moderator
Statistics
20925 users are registered to the Telelogic System Architect forum.
There are currently 1 users logged in.
The most users ever online was 16 on 30-Oct-2008 at 14:46.
There are currently 0 guests browsing this forum, which makes a total of 1 users using this forum.
You have posted 0 messages to this forum. 0 overall.

FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.