AVEVA Community
Site
Search
User
Site
Search
User
AVEVA World
PDMS/E3D Forum
Macros & Tools
total cutlength of pipe(totalling bran clle)
Forums
Resources
Mentions
Sub-Groups
Tags
More
Cancel
New
Replies
3 replies
Subscribers
14 subscribers
Views
101 views
Users
0 members are here
Options
Share
More
Cancel
Related
total cutlength of pipe(totalling bran clle)
Venkata Rao Peta
over 12 years ago
Venkata Rao Peta
over 12 years ago
[COLOR=#0000ff]!bran = !!collectallfor(|BRAN|,||,!!CE)[/COLOR]
[COLOR=#0000ff]!bransiz = !bran.size()[/COLOR]
[COLOR=#0000ff]do !j from 1 to !bransiz[/COLOR]
[COLOR=#0000ff]!cllelen = clle of $!bransiz[$!j][/COLOR]
[COLOR=#0000ff]!clletotal = !cllelen + !clletotal[/COLOR]
[COLOR=#0000ff]enddo[/COLOR]
[COLOR=#0000ff]$p Total pipe cutlength is $!clletotal
[/COLOR]How to add the clle of branches in a pipe.
/Thanks in advance
Cancel
Vote Up
0
Vote Down
Sign in to reply
Cancel
Tomas Veleman
over 12 years ago
collect all bran and run this macro in cycle for every of them ....
Cancel
Vote Up
0
Vote Down
Sign in to reply
Cancel
Thomas Back
over 12 years ago
!pipes = !!collectallfor(|PIPE|,||,!!ce)
!output = array()
do !pipe values !pipes
!len = 0
!branches = !!collectallfor(|BRAN|,||,!pipe)
do !bran values !branches
!len = !len + !bran.cllen
enddo
!output.append(!pipe.name & | Length: | & !len )
enddo
q var !output
Cancel
Vote Up
0
Vote Down
Sign in to reply
Cancel