NXC
Version 1.2.1 r5
Main Page
Related Pages
Modules
Data Structures
Files
Examples
All
Data Structures
Files
Functions
Variables
Groups
Pages
ex_StrReplace.nxc
This is an example of how to use the
StrReplace
function.
task main()
{
string
msgs[] = {
"please work"
,
"testing, 1, 2, 3"
};
string
a =
"AA"
, b =
"BB"
, c =
"CC"
;
TextOut
(0,
LCD_LINE4
,
StrReplace
(msgs[0], 2,
StrCat
(a, b)));
string
msg =
StrReplace
(
"testing"
, 3,
"xx"
);
// returns "tesxxng"
Wait
(
SEC_5
);
}
Generated by
1.8.2