18.12.2012 Views

Embedding R Tutorial

Embedding R Tutorial

Embedding R Tutorial

SHOW MORE
SHOW LESS

Create successful ePaper yourself

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

Data Transfer: Special Values<br />

� to use xlErr* constants add a reference to “Microsoft<br />

Excel x.y Type Library“<br />

xlErr* constant<br />

xlErrNA<br />

xlErrDiv0<br />

xlErrNull<br />

numeric value<br />

2042<br />

2007<br />

2000<br />

� use CVErr to create/access special values<br />

r.SetSymbol "sv1", CVErr(xlErrNA)<br />

r.SetSymbol "sv2", CVErr(xlErrDiv0)<br />

s1 = r.GetSymbol("sv1")<br />

If s1 = CVErr(xlErrNA) Then<br />

...<br />

End If<br />

� xlErrNull should not be used at the moment

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

Saved successfully!

Ooh no, something went wrong!