Gato
Joined: 19 Feb 2010 Posts: 3
|
Posted: Fri Feb 19, 2010 8:34 am Post subject: Digits String not treated as a number. |
|
|
Hello. This one must be very simple, but I just canīt find my way thru:
I need to extract a number from a Window Title and then to multiply this number 2.5 times.
| Code: |
Title = $1.15 NL Hold'em [Double or N... - Tournament 244599760 Table 1 - Blinds $1000/$2000
StringMid, bb, Title, Instr(Title, "/")+2 ;This is the numeric string I need
Bet25 =: 2.5 * %bb% : This is the multiplicatition.
NumPadRight::
MsgBox BB: %bb% ;Message box gives BB: 2000, as expected
Return
NumPadDown::
MsgBox Apuesta: %Bet25% ;This one is not a number, it gives 2.5 * 2000.
Return
|
Per the tutorial I assumed that bb, as a string consisting only of digits would be treated as a numeric variable when required, but this is not the case.
I really will very much appreciate your help.
Regards
Last edited by Gato on Fri Feb 19, 2010 8:38 am; edited 1 time in total |
|