Sima 
i grabed the last number after the "."
apendad it by 1 then grabed the first set of numbers manualy added the
periond, then the last 2 digits & re inswerted it into the table.

i thought i was treating the last number as a string?

<cfset firstnumber = listfirst(#FORM.Proj_Num#,".")>
<cfset lastnumber = listlast(#FORM.Proj_Num#,".")+01>
<cfset MyNum = "#firstnumber#.#lastnumber#">

if i use increment value it always put in 1
which = .1 not .01
most my numbers in my origional table are

Project_Num_Number
900166.11
900166.12
900168.00
900170.19
901007.02
901013.00

so if it is .00 i need .01
if .19 then i need .20

to make it even funner sone project numbers have 900170.19.56 
2 deciamal places.

thank you

-paul



-----Original Message-----
From: Sima Lee [mailto:[EMAIL PROTECTED]]
Sent: Monday, October 29, 2001 4:26 PM
To: CF-Talk
Subject: RE: Val :: IncrementValue by 01 NOT 1? how?


Hi Paul,

Can you treat the lastnumber as a string again and take the last number
of the lastNumber and increase it?
Or:
Did you try to take off all the "." and treat it as a number  increase
it by 1, then insert the dot back. Of course you have to remember how
many dots you have took off and the positions in the string.

HTH
Sima




-----Original Message-----
From: Paul Ihrig [mailto:[EMAIL PROTECTED]]
Sent: Monday, October 29, 2001 3:27 PM
To: CF-Talk
Subject: Val :: IncrementValue by 01 NOT 1? how?


ok
i can do this

<cfoutput>
<cfset firstnumber = listfirst(#FORM.Proj_Num#,".")>
<cfset lastnumber = IncrementValue(listlast(#FORM.Proj_Num#,"."))>
<cfset MyNum = "#firstnumber#.#lastnumber#">
<CFSET Proj_Num2 = #MyNum#>
</cfoutput>

But how do i make it insert 01 instead of 1?

-paul


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to