学内容: 

文件重命名rename

文件删除remove

 

文件重命名rename

int rename( const char *oldname, const char *newname );

oldname //需要重命名的文件名

newname //新的文件名

文件删除remove

int remove( const char *path );

 

文件全路径

c:\\windows\\system\\test.txt 不能写为c:\windows\system\test.txt

因为\\才表示"\"

文件名不能包含:/\*?"<>| 这几个字符

相关文章:

  • 2022-12-23
  • 2021-12-15
  • 2022-12-23
  • 2022-12-23
  • 2021-08-15
  • 2021-11-20
  • 2022-02-15
  • 2021-10-09
猜你喜欢
  • 2022-12-23
  • 2021-10-21
  • 2022-12-23
  • 2021-07-17
  • 2022-12-23
  • 2021-10-18
相关资源
相似解决方案