Subject: RE: [xsl] Incrementing a Variable From: "Jon Wynacht" <jwynacht@xxxxxxxxx> Date: Thu, 10 May 2001 15:53:03 -0700 |
I think I need to be more specific. Given the following xml: <?xml version="1.0" encoding="UTF-8"?> <EditQuery> <Object> <com.cisco.elobit.eeng.bug.AvailableFieldList> <AvailableField> <Name>Project</Name> <Id>1000</Id> <FormType>SELECT</FormType> <FieldType>CHARACTER</FieldType> <FieldLength>30</FieldLength> <FieldOrder>1</FieldOrder> <IntrinsicField>true</IntrinsicField> <ValueElement>ANY</ValueElement> <ValueElement>alpha project</ValueElement> </AvailableField> </com.cisco.elobit.eeng.bug.AvailableFieldList> </Object> <Object> <com.cisco.elobit.eeng.bug.ComplexQuery> <id>142002</id> <complexQueryField> <availableFieldId>1000</availableFieldId> <name>Project</name> <condOperator>=</condOperator> <fieldValue>ffe</fieldValue> <fieldLogical>AND</fieldLogical> <createdDate>5/9/2001</createdDate> <modifiedDate>5/9/2001</modifiedDate> </complexQueryField> </com.cisco.elobit.eeng.bug.AvailableFieldList> </Object> </EditQuery> I loop through the <AvailableField> elements and for each one I do some nifty HTML and I give that particular element I'm working on a number using position() - 1 so the number always starts with 0. Each time I'm inside the <AvailableField> element, I need to step out and check the <complexQueryField> elements, compare their id with the Id in <AvailableField> and if they match, do some nifty HTML and increment my counter. Problem is I need to know where my increment is for the next turn of events. I thought there was an xsl:counter but that doesn't seem to be supported anymore. Anyone have suggestions or ideas? Thanks in advance, Jon -----Original Message----- From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx [mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx]On Behalf Of Jon Wynacht Sent: Thursday, May 10, 2001 3:24 PM To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Subject: [xsl] Incrementing a Variable Hey Group, It was my understanding that you can increment a variable in xsl by 1, say during each pass of a for loop. Is this true and if not, what's the best way to achieve this? Thanks, Jon XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] Incrementing a Variable, Jon Wynacht | Thread | Re: [xsl] Incrementing a Variable, David Carlisle |
Re: [xsl] apply-templates, rule-bas, Thomas B. Passin | Date | [xsl] Reformatting, Brucato, Greg |
Month |