{ From user David, Model text_node_update at 25-Jul-2013 1:03:44 PM, encoding="UTF-8" } SoftwareVersion 4.5.0 { System Variables with non-default values: } TypeChecking := 1 Checking := 1 SaveOptions := 2 SaveValues := 0 {!-40203|Attribute CloudPlayerStyles} Attribute Prev_attribute AskAttribute Prev_attribute,Function,Yes AskAttribute Prev_attribute,Module,Yes AskAttribute BalloonHelp,Variable,Yes AskAttribute Prev_attribute,Variable,Yes Model text_node_update Author: Fred Date: Tue, Jun 18, 2013 8:07 AM SaveAuthor: David SaveDate: Thu, Jul 25, 2013 1:03 PM DiagState: 2,18,16,710,601,17 WindState: 2,102,83,476,224 DiagramColor: 52428,52428,52428 FontStyle: Arial,15 FileInfo: 0,Model text_node_update,2,2,0,0,C:\Documents and Settings\David\Desktop\work\Changes to wiki\What's new in ACP\text node update.ana {!40400|CloudPlayerStyles: show_outline:no~ show_tabs:no~ show_parent_diagram_button:no~ Navigation_style:top_tabs~ } {!40204-40399|AWP_Attrib:show_outline:no~ show_tabs:no~ show_parent_diagram_button:no~ Navigation_style:top_tabs~ } Variable Change_Text Title: Change Text Description: The function updates the text node description in ACP and then displays the result. Definition: Update_text( ) NodeLocation: 536,280,1 NodeSize: 48,24 WindState: 2,489,321,761,224 ValueState: 2,418,167,759,303,0,MIDM Aliases: FormNode Va2 Text myTextNode Description: good morning NodeLocation: 532,92,-1 NodeSize: 140,36 NodeInfo: 1,0,0,1,0,0,1,,0,,0 WindState: 2,656,218,476,224 NodeColor: 65535,0,0 NodeFont: Arial Black,27 {!40000|NodeFontColor: 62500,0,0} Function Update_text() Title: Update text () Description: A Function demonstrating how to update the description of a text node on the ACP diagram. Definition: {Evaluate the if - then - else expression, then changes the description of the text node or leaves it alone.}~ ~ if (description of myTextNode = "good morning") then~ evaluateScript("Description of myTextNode : good night")~ else~ evaluateScript("Description of myTextNode : good morning");~ ~ {Return a result which will show on the diagram.}~ ~ "here is the result" NodeLocation: 536,216,1 NodeSize: 48,24 WindState: 2,371,96,554,478 Button Update_text_button Title: Update text button Description: You can use this button to change the text. NodeLocation: 120,84,1 NodeSize: 48,28 Script: Update_text(); FormNode Va2 Title: Va1 Definition: 1 NodeLocation: 204,152,1 NodeSize: 132,16 NodeInfo: 1,0,0,1,0,0,0,126,0,1, Original: Change_Text Close text_node_update