Pada Tue, 25 Aug 2009 04:29:32 -0600 Dimitris Anogiatis <dos...@gmail.com> menulis:
> give it a try MSulchan and tell me if it works for you Thank you Dimitris, after a little try and error, I change the code into like this : IF IsNull(Val(sRain)) = FALSE THEN IF InStr(LCase(sRain), "x") > 0 OR InStr(sRain, "-") > 0 OR InStr(sRain, ".") > 0 THEN IF InStr(LCase(sRain), "x") > 0 THEN fRain = 0 IF InStr(sRain, "-") > 0 THEN fRain = 0 IF InStr(sRain, ".") > 0 THEN sRainy = Replace(sRain, ".", ",") fRain = Val(sRainy) ENDIF ELSE fRain = CFloat(Val(sRain)) ENDIF ELSE fRain = -1 ENDIF Decided to change iRain (integer) to fRain (float). As Fabien told that Val() use current localization, so I need to change the decimal separator from dot to comma. And I think it is fast enough :D Thanks again. -- Cheers, [-Sulchan-] Terbang dengan claws-mail 3.7.2 Mendarat di hardy heron 8.04.3 LTS
signature.asc
Description: PGP signature
------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july
_______________________________________________ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user