SRL Archive - Help and Support

ExtractFromStr support Extended/Float?


Claymore

2010-09-08 02:41:14

Solved problem sorry bout this.

Daniel

2010-09-08 03:23:49

Perhaps restate your problem and the answer you came up with to support others that might encounter the same problem?

Claymore

2010-09-08 03:31:52

Alright.

Upon developing a addition to my script, the procedure of calculating profits for each option the user can invest to. (Ok to sum up, when Superheating you can earn profit when ores are low and bars are high.) I stumble to a problem.

You see the G.E uses K's or M's instead of giving absolute value if the price is greater than 9,999.

SO! When i used


ExtractFromStr('16.5k', Numbers);
//Assume when i used Between('<b>Market Price: </b>', #39+'</span>, GetPage('RS Item Price URL'));i got 16.5k

The Result is 165, not 16.5.

I thought mmk, bout…


ExtractFromStr('16,5', Extended);

Error, Extended is an invalid..etc…

Turns out i could just do this.


Replace('16.5k', 'k', '');

There we go!

Bonfield

2010-09-08 04:58:49

You don't want to know the exact price of the item?