回复 2楼 wp231957
我的意思是写个函数将数据直接导出到Excel里面
void daochu(FILE *fp,int count,struct student num[])
{
int i,j;
strcat(
,".csv");//这个笑脸这里不知道填什么了
fp=fopen("student.txt","wb");
fprintf(fp,"%s,%s,%s,%s,%s\n","姓名","性别","移动电话","电子邮件","家庭住址");
for(i=0;i<count;i++)
{
fprintf(fp,"%s,%s,%s,%s,%s\n",num[i].name,num[i].sex,num[i].mov,num[i].email,num[i].address);
fclose(fp);
}
}