CString理解——字符串替换函数 1 #include<stdio.h> 2 #include<string.h> 3 #include<stdlib.h> 4int Replace(char *sSrc, char *sMatchStr, char *sReplaceStr)5 { 6int StringLen;7char caNewString[100];8char *FindPos = strstr(sSrc, sMatchStr);//strstr(str1,str2) 函数⽤于判断字符...
CString a = "asdfghjkllkjhgfdsa";CString b = "abcde";a.Replace("asd",b);这样就把a中的前三个字母位置替换成了abcde,此刻a为abcdefghjkllkjhgfdsa
CString::Replace