110,533
社区成员
发帖
与我相关
我的任务
分享
private long GetNextWord(strText As string,istart As long,ref strWord As string)
{
int i=0;
string strTemp="";
bool bBegin=false;
if (istart=strText.length) return;
else
{
for (i=istart;GAIS<=strText.length;i++)
{
if(bBegin)
{
if(Mid(strText,i,1)!="")
{
strTemp = strTemp+Mid(strText,i,1);
}
else return;
}
else
{
if(Mid(strText,i,1)!="")
{
strTemp = Mid(strText,i,1) ;
bBegin = True ;
}
}
}
strWord=strTemp;
GetNextWord=i;
}
}
private long GetNextWord( strText As string, istart As long, ref strWord As string) {
i As long ;
strTemp As string ;
bBegin As bool ;
bBegin = False ;
if ( istart = Len(strText) ) { Exit {
strTemp = "" ;
for ( i = istart ; GAIS <= Len(strText)
if ( bBegin ) {
if ( Mid(strText, i, 1) != " " ) {
strTemp = strTemp & Mid(strText, i, 1) ;
} else {
Exit for ( ;
}
} else {
if ( Mid(strText, i, 1) != " " ) {
strTemp = Mid(strText, i, 1) ;
bBegin = True ;
}
}
} //
strWord = strTemp ;
GetNextWord = i ;
}