Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Strip off decimal point and comma in text export 1

Status
Not open for further replies.

kpeak

IS-IT--Management
Mar 10, 2004
12
US
I am using the following formula to strip the decimal point out of a 7 position numeric field when I export to a text file. Is there an easy way to use this formula to also remove the comma thousands separator?

replicatestring(" ", 7 - len(replace(totext({@gross_adj}),".",""))) + replace(totext({@gross_adj}),".","")

(example: @gross_adj = 1,320.79
want to export as 132079)

 
Try:

replicatestring(" ", 7 - len(replace(totext({@gross_adj},2,""),".",""))) +
replace(totext({@gross_adj},2,""),".","")

-LB
 
Thanks...worked like a charm!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top