Welcome, Guest. Please Login
Tinderbox
  News:
IMPORTANT MESSAGE! This forum has now been replaced by a new forum at http://forum.eastgate.com and no further posting or member registration is allowed. The forum is still accessible via read-only access for reference purposes. If you wish to discuss content here, please use the new forum. N.B. - posting in the new forum requires a fresh registration in the new forum (sorry - member data can't be ported).
  HomeHelpSearchLogin  
 
Pages: 1
Send Topic Print
^action()^ inside $DisplayExpression (Read 428 times)
Scott Heftler
Full Member
*
Offline



Posts: 33

^action()^ inside $DisplayExpression
Jul 15th, 2016, 12:53am
 
Just discovered that I can put ^action()^ inside $DisplayExpression. Specifically, I use it to set the $Subtitle as well.  So both the title and the subtitle of the note in Map View are set at once.  Specifically, the DisplayExpression is this:

"Theme Folder" + ^action($Subtitle=$ThemeName)^

My question is: How taxing is this?  I wanted to find something like a $Rule but which only runs when an attribute is changed.  Is the condition-checking that goes on inside $DisplayExpression just as taxing as a $Rule?  Does adding this ^action()^ here bog things down?
Back to top
 
 
  IP Logged
Mark Bernstein
YaBB Administrator
*
Offline

designer of
Tinderbox

Posts: 2871
Eastgate Systems, Inc.
Re: ^action()^ inside $DisplayExpression
Reply #1 - Jul 15th, 2016, 6:31am
 
DisplayExpression is evaluated every time a note's display name is needed; in general, it will be more costly than a rule. Occasional indulgence is probably fine, but in general I'd avoid this technique.
Back to top
 
 
WWW   IP Logged
Pages: 1
Send Topic Print