getting message bar text in HW 2020x was ".mainFrame.bottom.message_label cget -text" in 2019.

Peter Randle
Peter Randle Altair Community Member
edited October 2021 in Community Q&A
Hi All
I am trying to grab text from the message bar.
E.G.
".mainFrame.bottom.message_label cget -text" Does not work in 2020x is there another way?
I am trying to get
image
to understand that the correct units have been used.
 
 
set ttname "SHELLSECTION"
set scal 1000.0
*createmark elements 1 "by config" tetra10
*createmark elements 2
*elementtestlength elements 1 20 2 0 4 0 " 3D Length >"
if {[catch {set mm [split [.mainFrame.bottom.message_label cget -text] { }] ]} {set mm [split [.mainFrame.bottom.leftfrm.label cget -text] { }]}
set mmm [lindex $mm 9]
set mmm [string range $mmm 0 end-1]
puts "max length = $mmm"
Tagged:

Answers

  • Ben Buchanan
    Ben Buchanan
    Altair Employee
    edited October 2021

    If you use hm_getelemcheckbounds 1 2 maxlength it will return the desired value as the second value.