11.04.2013 Views

UniBasic Commands Reference - Rocket Software

UniBasic Commands Reference - Rocket Software

UniBasic Commands Reference - Rocket Software

SHOW MORE
SHOW LESS

Create successful ePaper yourself

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

SPLICE<br />

Syntax<br />

SPLICE(expr1,"expr", expr2)<br />

Description<br />

The <strong>UniBasic</strong> SPLICE function concatenates two strings or arrays and inserts an<br />

expression between them.<br />

Parameters<br />

The following table describes each parameter of the syntax:<br />

Parameter Description<br />

Examples<br />

In the following example, the program segment concatenates PHONE to NUMBER<br />

and inserts a dash (-) between the two strings:<br />

1-778 <strong>UniBasic</strong> <strong>Commands</strong> <strong>Reference</strong><br />

expr1 Specifies the first string or array to concatenate.<br />

expr Specifies the expression to insert between expr1 and expr2 when concatenating<br />

them.<br />

expr2 Specifies the second string or array to concatenate.<br />

SPLICE s arameter<br />

PHONE = "555"<br />

NUMBER = "1234"<br />

PRINT SPLICE (PHONE,"-",NUMBER)<br />

This results in:<br />

555-1234

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

Saved successfully!

Ooh no, something went wrong!