TCL Command ABMPROFILE

Inhalt

Index

Syntax

array set prof [ABMPROFILE profid GET]

array set ppnts [ABMPROFILE profid GET PPNTLIST]

array set elems [ABMPROFILE profid GET ELEMLIST]

Description

Query the profile data

Query the list of polygon points of the profile

Query the list of the profile elements

Argument

Dimension

Meaning

profid

OBJID

Object-ID of profile

GET

KEYWORD

Query data

PPNTLIST

KEYWORD

Query the list of polygon points

ELEMLIST

KEYWORD

Query the list of profile elements

Return array for [ABMPROFILE ... GET]

Array item

Dimension

Meaning

error

INT

Error code

info

TEXT

Object or error information

id

OBJID

Object-ID

name

TEXT

Name of profile

scale

DOUBLE

Scale factor for representation

active

INT

0 – not active, 1 - active

terrain

TEXT

Name of the terrain if used

Return array for [ABMPROFILE ... GET PPNTLIST] or [ABMPROFILE ... GET ELEMLIST]

Array item

Dimension

Meaning

error

INT

Error code

info

TEXT

Error information

first

OBJID

Object-ID of the first list element

last

OBJID

Object-ID of the last list element

count

INT

Number of list elements

Scopes

All

Examples

array set prof [ABMPROFILE $profID GET]

if { $prof(active) != 0 } {

puts $outfile "Profile '$prof(name)' (active)"

} else {

puts $outfile "Profile '$prof(name)' (not active)"

}

It is assumed that a text file outfile has been opened for writing . The profile name and its status are written to the text file.

array set prof [ABMPROFILE $profID GET]

array set polygon [ABMPROFILE $profID GET PPNTLIST]

if { $polygon(count) > 0 } {

set ppntID $polygon(first)

for { set ippnt 0 } { $ippnt < $polygon(count) } { incr ippnt } {

if { $ippnt > 0 } { set ppntID [OBJNEXT $ppntID] }

array unset ppnt

array set ppnt [ABMPROFPPNT $ppntID GET]

}

}

array set elements [ABMPROFILE $profID GET ELEMLIST]

if { $elements(count) > 0 } {

set elemID $elements(first)

for { set ielem 0 } { $ielem < $elements(count) } { incr ielem } {

if { $ielem > 0 } { set elemID [OBJNEXT $elemID] }

array unset elem

array set elem [ABMPROFELEM $elemID GET]

}

}

The profile data is queried. The list of polygon points is queried and traversed. The profile ID has already been set in advance. The polygon points are queried in a loop. The list of profile elements is queried and traversed. The profile elements are queried in a loop.



Allplan

(C) ALLPLAN GmbH

Privacy policy