VS写文件

版权声明:墨痕诉清风 https://blog.csdn.net/u012206617/article/details/84841328

FILE* fp = fopen(strFileNameDes.c_str(), "w");

string strFourBlanks = "    ";
string strEightBlanks = "        ";

fprintf(fp,"%s\n", "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>");
fprintf(fp,"%s\n", "<result>");

fprintf(fp,"%s%s\n", strEightBlanks.c_str(), "</viruss>");

fclose(fp); 

猜你喜欢

转载自blog.csdn.net/u012206617/article/details/84841328
今日推荐