I am trying to create a report where a almost-sequential number is to show next 
to each row.  I say "almost" because there are certain circumstances that I 
need to add 2 instead of 1 to that number.  

Now I started off by creating a function in the report builder.  Here it is...  
Simply put, I pass in a number and it figures out how many to add to it.  Then 
it sends that back to the report.

<cffunction name="calcNextAudit">
<cfargument name="nextAudit" type="numeric">
<cfargument name="voids" type="string">

<cfset goodAudit = "N">
<cfloop condition="goodAudit EQ 'N'">
        <cfif listFind(voids, nextAudit)>
        <cfelse>
                  <cfset goodAudit = "Y">
    </cfif>
    <cfset nextAudit = nextAudit + 1>
</cfloop>
<cfreturn nextAudit >
</cffunction>

In the expression builder I have put: 
#report.calcNextAudit(param.startAudit, param.voids)#


The problem I have is that the same number is printing over and over.  I can't 
figure out how to keep the new value I received from the function in the 
report.  If I could then the idea would be to send it into the function on the 
next record to get the next higher number.

I hope this makes sense.  I guess I only see a function as my solution to 
printing this number per record.  So how do I keep the value saving the 
function result. 

Thanks for any help.
Kim


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;160198600;22374440;w

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:299809
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to