Skip to Content
0

HCI: XSLT get property value

Oct 26, 2017 at 02:34 PM

335

avatar image

Hi Team,

I'm working with HCI and I'm doing some XSLT programming.

However I want to get the params that are set in the properties of the HCI container, and set the value in a XML tag. Does anybody has an idea?

KR,

MAssarrar

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

Best Answer
Sriprasad Shivaram Bhat
Oct 27, 2017 at 03:18 AM
1

Hello Mohammed,

You have to create a property with name Param1 and you can access the same like below

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:hci="http://sap.com/it/" exclude-result-prefixes="hci">
	<xsl:param name="Param1"/>
	<xsl:output method="xml" encoding="UTF-8" indent="no" />
	<xsl:template match="/">
		<k>
			<xsl:value-of select="$Param1"/>
		</k>
	</xsl:template>
</xsl:stylesheet>

Regards,

Sriprasad Shivaram Bhat

Show 1 Share
10 |10000 characters needed characters left characters exceeded

I have set a property in groovy script and want to access it in next XSLT mapping. It does not return me the expected result. Can u advise?

<?xmlversion="1.0"encoding="UTF-8"?>

<xsl:stylesheetversion="2.0"

xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:paramname="payDate"/>

<xsl:templatematch="queryCompoundEmployeeResponse">

<xsl:copy>

<xsl:copy-ofselect="CompoundEmployee[person/employment_information/paycompensation_non_recurring/pay_date >= '$payDate']"/>

</xsl:copy>

</xsl:template>

</xsl:stylesheet>

0
M Assarrar Oct 27, 2017 at 07:23 AM
0

Great Sriprasad Shivaram Bhat!! Thanks.

Share
10 |10000 characters needed characters left characters exceeded