How to convert Decimal number with comma(,) as decimal separator to dot(.)

  • Follow


Hi,

I am having problem with decimals in VBA code.
I am "injecting" value from textbox into UPDATE sql statment, but I get an
error because i am having comma as a separator.
How to convert 0,254 into 0.255 without changing regional settings! 


0
Reply Domac 5/10/2006 11:26:40 AM

Use the replace function:

Replace("String",",",".")
-- 
hth,
SusanV


"Domac" <domac.kovacevic@zg.t-com.hr> wrote in message 
news:%238PfdSCdGHA.4900@TK2MSFTNGP02.phx.gbl...
> Hi,
>
> I am having problem with decimals in VBA code.
> I am "injecting" value from textbox into UPDATE sql statment, but I get an
> error because i am having comma as a separator.
> How to convert 0,254 into 0.255 without changing regional settings!
> 


0
Reply SusanV 5/10/2006 12:04:37 PM


1 Replies
2406 Views

(page loaded in 0.039 seconds)


Reply: