Difference between revisions of "ParseToNumber Command"
From GeoGebra Manual
(added link to ParseToFunction) |
|||
Line 2: | Line 2: | ||
{{command|scripting}} | {{command|scripting}} | ||
;ParseToNumber[ <Number>, <String> ] | ;ParseToNumber[ <Number>, <String> ] | ||
− | :Parses the string and stores the result to [[Numbers and Angles|number]] ''a'' | + | :Parses the string and stores the result to a [[Numbers and Angles|number]] ''a'', which must be defined and [[Free, Dependent and Auxiliary Objects|free]] before the command is used. |
− | :{{example|1= | + | :{{example|1=Define <code><nowiki> a = 3</nowiki></code> and <code><nowiki> text1 = "6"</nowiki></code>. <code><nowiki> ParseToNumber[a, text1]</nowiki></code> returns ''a = 6''.}} |
+ | {{note|1=See also [[ParseToFunction Command|ParseToFunction ]] command. }} |
Revision as of 09:22, 21 July 2013
- ParseToNumber[ <Number>, <String> ]
- Parses the string and stores the result to a number a, which must be defined and free before the command is used.
- Example: Define
a = 3
andtext1 = "6"
.ParseToNumber[a, text1]
returns a = 6.
Note: See also ParseToFunction command.