ExecFunc
var result = ExecFunc(func);
Parameters
- func : String, Definition of the function like listed below.
func | Description |
---|---|
ConvertDate | Converts one date format into an other format |
SetGlobal | Set Global Variable, Variable set in JavaScript can be used in a called XSL |
GetGlobal | Get Global Variable, Variable set in called XSL can be used in JavaScript |
Math | Some mathematical functionality |
Return Values
Contains result of the function or null if an error occured.
Remarks
Example
JavaScript:
var strDateMMM = ExecFunc("ConvertDate(' + strPDate + ',yyyy-mm-dd,ddMMMyy)");
var var strJourneyTime = ExecFunc("Math(AddTime,' + journeyTime + ',' + currentJourneyTime + ',hhmm,hhmm)");
XSLT:
<CreationDate>
<xsl:value-of select="concat('!func:ConvertDate(',dateValue,',ddMMMyy,yyyy-mm-dd)')"/>
</CreationDate>
<NumberOfNights>
<xsl:value-of select="concat('!func:Math(SubDate,',HODDAT/E021E,',',HODDAT/E021D,',ddMMMyyyy,ddMMMyyyy)')"/>
</NumberOfNights>