Originally Posted by
Barbarossa
Function DisplayCurrency(Amount)
Dim currentLocale
Dim original
currentLocale = GetLocale
original = SetLocale("en-gb")
if isnumeric(Amount) Then
if Amount < 0 Then
DisplayCurrency = "-£" & FormatNumber(0-Amount,2)
else
DisplayCurrency = "£" & FormatNumber(Amount,2)
End if
else
DisplayCurrency = Amount
End if
original = SetLocale(currentLocale)
End Function
Function ConvertCurrency(Amount)
TempAmount = Amount
while (not isnumeric(left(TempAmount,1))) and (len(TempAmount) > 0)
TempAmount = trim(mid(TempAmount,2,len(TempAmount)))
wend
if isnumeric(TempAmount) Then
ConvertCurrency = ccur(Round(TempAmount,2))
else
ConvertCurrency = TempAmount
End if
End Function
Bookmarks