You can also go the other way around by converting the value of a real variable into a string. This operation, however, requires that you know more about how you would like the number represented. Look at the comments in the next code example for an explanation of the parameters.
static void Datatypes_num2str(Args _args)
{
str mileage;
real mileageNum;
;
mileageNum = 388272.23;
// num2str(number to be converted,
// minimum characters required,
// required number of decimals,
// decimal separator <1=point, 2=comma>,
// thousand separator <0=none, 1=point,
// 2=comma, 3=space>)
mileage = num2str(mileageNum,0,2,2,0);
print strfmt("The car has run %1 miles", mileage);
pause;
}
The above Job will print: The car has run 388272,23 miles
static void Datatypes_num2str(Args _args)
{
str mileage;
real mileageNum;
;
mileageNum = 388272.23;
// num2str(number to be converted,
// minimum characters required,
// required number of decimals,
// decimal separator <1=point, 2=comma>,
// thousand separator <0=none, 1=point,
// 2=comma, 3=space>)
mileage = num2str(mileageNum,0,2,2,0);
print strfmt("The car has run %1 miles", mileage);
pause;
}
The above Job will print: The car has run 388272,23 miles
Thanks to the admin you have spend a lot for this blog I gained some useful info for you. Keep doing.
ReplyDeletemicrosoft dynamics crm training institutes in chennai
microsoft dynamics training
CCNA Training in Chennai
Salesforce Training in Chennai
gst classes in chennai
microsoft crm training