11.07.2015 Views

webMathematica™ Wolfram - Wolfram Research

webMathematica™ Wolfram - Wolfram Research

webMathematica™ Wolfram - Wolfram Research

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

260 webMathematica User GuideHere the variable $$var is assigned to the value "5+7"; note that the value is a string.In[3]:= $$var = "5+7";When MSPToExpression evaluates, the parsed value of $$var is returned.In[4]:=MSPToExpression@ $$varDOut[4]= 12If a variable has no value, an MSPException is thrown.In[5]:=Clear@ $$varD; MSPToExpression@ $$varDThrow::nocatch :Uncaught Throw@$$var, MSPException@NoValueErrorDD returned to top level.Out[5]= Hold@Throw@$$var, MSPException@NoValueErrorDDDLike ToExpression, MSPToExpression can take a format type for interpretation.In[6]:=$$var = "sinHxL"; MSPToExpression@ $$var, TraditionalFormDOut[6]= Sin@xDIf the input value cannot be interpreted, an MSPException is thrown.In[7]:=$$var = "Sin@"; Catch@ MSPToExpression@ $$varD, _MSPException, ListDOut[7]= 88$$var, Sin@

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!