Inspects the function call for a previously applied behavior in the user's document and sets the values of the options in the Parameters dialog box accordingly. If inspectBehavior() is not defined, the default option values appear.
Note: inspectBehavior() must rely solely on information that the applyBehaviorString argument passes to it. Do not attempt to obtain other information about the user's document (for example, using .getDocumentDOM() ) within this function.
applyBehaviorString
This argument is the string that the applyBehavior() function returns.
expects nothing.
The following instance of inspectBehavior() , taken from Display Status Message.htm, fills in the Message field in the parameters form with the message that the user selected when the behavior was originally applied:
function inspectBehavior(msgStr){ var startStr = msgStr.indexOf("'") + 1; var endStr = msgStr.lastIndexOf("'"); if (startStr > 0 && endStr > startStr) { document.theForm.message.value = ¬ unescQuotes(msgStr.substring(startStr,endStr)); } }Note: For more information about the unescQuotes() function, see the dwscripts.js file in the Configuration/Shared/Common/Scripts/CMN folder.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117