ro-users@lists.pharo.org>> wrote:
-- Forwarded message --
From: Benoit St-Jean mailto:bstj...@yahoo.com>>
To: Any question about pharo is welcome mailto:pharo-users@lists.pharo.org>>
Cc:
Date: Sat, 4 Apr 2015 23:40:01 + (UTC)
Benoit St-Jean
> To: Any question about pharo is welcome
> Cc:
> Date: Sat, 4 Apr 2015 23:40:01 + (UTC)
> Subject: Re: [Pharo-users] Converting a string containing dots to integer
> Do you have more details?
>
> Such as, do you have values with more than one dot
--- Begin Message ---
This might do the trick:
(Number readFrom: ('8.524.757' copyReplaceAll: '.' with: '')) asIntegeror even
nicer (and simpler)
('8.524.757' reject: [:char | char == $.]) asInteger
-
Benoit St-Jean
Yahoo! Messenger: bstjean
Twitter: @BenLeChialeux
Pinterest: beno
--- Begin Message ---
Do you have more details?
Such as, do you have values with more than one dot ? (e.g. 1.436.782)Do you
have values with no dot? -
Benoit St-Jean
Yahoo! Messenger: bstjean
Twitter: @BenLeChialeux
Pinterest: benoitstjean
IRC: lamneth
Blogue: endormitoire.wordp