答案 0 :(得分:0)
您的代码中没有定义data have;
infile datalines delimiter=':' truncover;
informat target $50.;
input target;
datalines;
aaa
bbb
aaa bbb
bbb aaa
ccc aaa
ccc bbb
bbb ccc
;
run;
data want;
set have;
RE = PRXPARSE("/aaa|bbb/");
CALL prxsubstr(RE,STRIP(target),start,length);
IF START GT 0 then DO;
TEST_STR = substrn(STRIP(target),start,length);
end;
ELSE DO;
TEST_STR = STRIP(target);
end;
drop re start length;
run;
。您的方法签名为:
aaa | aaa
bbb | bbb
aaa bbb | aaa
bbb aaa | bbb
ccc aaa | aaa
ccc bbb | bbb
bbb ccc | bbb
将e
更改为public void keyPressed(KeyEvent arg0)
,反之亦然。