| **Navigation:**  [[templates.htm|Templates]] > [[tlrcontents.htm|Template Language Reference]] > Complete Alpha Listing >====== #PRIORITY (set new embed priority level) {{c6h0068.jpg|C6H0068.jpg}} ====== | [[ print print a source file .htm|{{btn_prev_n.gif|Previous page}}]][[tlrcontents.htm|{{btn_home_n.gif|Return to chapter overview}}]][[ procedure begin a procedure template .htm|{{btn_next_n.gif|Next page}}]] | | || **#PRIORITY(** //number// **)** [,**DESCRIPTION**(//treedesc//) ] {{blk2blue.jpg|blk2blue.jpg}} | **#PRIORITY** | Specifies a new priority level for the code following the #PRIORITY statement. | | //number// | An integer constant in the range 1 to 10000. | | **DESCRIPTION** | An optional description of the priority point. | | | //treedesc //is a string constant or expression that will appear in the embed tree for this priority point. | The **#PRIORITY** statement specifies a new priority //number //for the code statements following the #PRIORITY. #PRIORITY is only valid when used in the #AT/#ENDAT structure. It cannot exist within other nested structures contained within the #AT/#ENDAT structure (e.g., #PRIORITY cannot be placed inside of a #CASE/'#ENDCASE which is nested within a #AT/#ENDAT). **Example:** **#CONTROL(BrowseList,'Add Browse List controls')** **  #AT(%ControlEvent,'?Insert','Accepted'),PRIORITY(5000)  #!Start at priority 5000** **GlobalRequest = InsertRecord                              #!Goes into priority 5000** ** ****#PRIORITY****(8500)****,DESCRIPTION('Before calling update procedure')** **%UpdateProc                                               #!Goes into priority 8500** **  #ENDAT** **#!** **See Also:     **[[ at insert code in an embed point .htm|#AT (insert code in an embed point)]] , [[ embed define embedded source point .htm|#EMBED]] , [[ code define a code template .htm|#CODE]] , [[ control define a control template .htm|#CONTROL]] [[ extension define an extension template .htm|#EXTENSION]]