S
sun2000
Unregistered / Unconfirmed
GUEST, unregistred user!
请看如下的定义:
AnsiString S = "Parent , wife", TokenStr = ',';
AnsiString Temp2 = S;
strtok(S.c_str(), TokenStr.c_str());
Edit1->Text = Temp2;
运行后:
S = "Parent ";
// 正常
Temp2 = "Parent ";
//不正常?????
我认为因该是 Temp2 = "Parent , wife";
??????
AnsiString S = "Parent , wife", TokenStr = ',';
AnsiString Temp2 = S;
strtok(S.c_str(), TokenStr.c_str());
Edit1->Text = Temp2;
运行后:
S = "Parent ";
// 正常
Temp2 = "Parent ";
//不正常?????
我认为因该是 Temp2 = "Parent , wife";
??????