                     
 	                // format the string accodingly to the formatter
 	                if (formater == STRING_FORMATTER){
-	                    match.replacement = padString(replacementValue.toString(), paddingNum, paddingChar);
+	                    match.replacement = padString(String(replacementValue), paddingNum, paddingChar);
 	                }else if (formater == FLOAT_FORMATER){
 	                    // floats, check if we need to truncate precision
 	                    if (precision){

	                }else if(DATES_FORMATERS.indexOf(formater) > -1){
	                    switch (formater){
	                        case DATE_DAY_FORMATTER:
	                            match.replacement = replacementValue.date;
	                            break
	                        case DATE_FULLYEAR_FORMATTER:
	                            match.replacement = replacementValue.fullYear;
	                            break
	                        case DATE_YEAR_FORMATTER:
	                            match.replacement = replacementValue.fullYear.toString().substr(2,2);
	                            break
	                        case DATE_MONTH_FORMATTER:
	                            match.replacement = replacementValue.month + 1;
	                            break
	                        case DATE_HOUR24_FORMATTER:
	                            match.replacement = replacementValue.hours;
	                            break
	                        case DATE_HOUR_FORMATTER:
	                            var hours24 : Number = replacementValue.hours;
	                            match.replacement =  (hours24 -12).toString();
	                            break
	                        case DATE_HOUR_AMPM_FORMATTER:
	                            match.replacement =  (replacementValue.hours  >= 12 ? "p.m" : "a.m");
	                            break
	                        case DATE_TOLOCALE_FORMATTER:
	                            match.replacement = replacementValue.toLocaleString();
	                            break
	                        case DATE_MINUTES_FORMATTER:
	                            match.replacement = replacementValue.minutes;
	                            break
	                        case DATE_SECONDS_FORMATTER:
	                            match.replacement = replacementValue.seconds;
	                            break    
	                    }
	                }else{
	                   //no good replacement

                match.endIndex = match.startIndex + match.length;
                match.content = String(result[0]);
                // try to get substitution properties
                formater = result["formater"];
                varName = result["var_name"];
                precision = result["precision"];
                padding = result["padding"];
				paddingNum = 0;
				paddingChar = null;
                //trace('formater:', formater, ', varName:', varName, ', precision:', precision, 'padding:', padding);
