[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: substring
Mike, It worked. Thanks -----Original Message----- From: Bhaskar, Rajan [mailto:RBhaskar@xxxxxxx] Sent: Friday, February 25, 2005 5:09 PM To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Subject: RE: substring I put it like this. if RxNum is 23. it just gives 23 and transformation does not work properly <RxNbr> <xsl:value-of select='format-number(rx:RefillRenewalRequest/rx:RxInfo/@RxNum,"0000000" )'/> </RxNbr> -----Original Message----- From: Michael Kay [mailto:mike@xxxxxxxxxxxx] Sent: Friday, February 25, 2005 4:18 PM To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Subject: RE: substring > How can i pad an attribute value with (zeros) if the lenght > is less that a fixed length > suppose i have > <Rx rxNum="1234"> but when transforming it should be 10 > digits with left padded 000 like > <Rx rxNum="0000001234"> > but sometimes we may just get <Rx rxNum="23"/> format-number(@rxNum, "0000000000") Michael Kay http://www.saxonica.com/
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|