I am faced with a puzzle that should be fairly easy to solve.

<cfoutput>
  <cfif Qty1_Value NEQ "">
  <tr bgcolor="cccccc">
  <td align="center">
   #Qty1_Value#
          </td>
          <td>
            #Desc1_Value#</td>
          <td nowrap align=center><CFIF #DropShip1_Value# EQ 1> Yes<cfelse>&nbsp;</CFIF></td>
          <td><CFIF #FindNoCase('S1',Shipped_Value)# GT 0> Yes<cfelse>&nbsp;</cfif></td>
  <td><CFIF #ItemDateShipped1_Value# NEQ ''>#ItemDateShipped1_Value#</CFIF></td>
  <td><CFIF #FindNoCase('O1',Ordered_Value)# GT 0> Yes<cfelse>&nbsp;</cfif></td>
  <td><CFIF #ItemDateOrdered1_Value# NEQ ''>#ItemDateOrdered1_Value#</CFIF></td>
  <td><CFIF #FindNoCase('N1',ItemNew_Value)# GT 0> Yes<cfelse>&nbsp;</cfif></td>
          <td><CFIF #FindNoCase('F1',ItemFixed_Value)# GT 0> Yes<cfelse>&nbsp;</cfif></td>
          <td>
            <cfif Price1_Value NEQ ''>#DollarFormat(Price1_Value)#</cfif></td>
        </tr>
  </cfif>
</cfoutout>

I want to repeat that same code a total of 15 times. I tried to use CFLOOP from=1 to=15 going through my query, but I don't know how to properly call the index within those CFIF tags.

For example, where it has Price1_Value, I want it to be something like Price#indexvalue#_Value so that it'll work 1 through 15.

So right now, I have that same code copied 15 times... talk about bloat!

I'd love the help. Thanks.
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to