1. #include <iostream>  
  2. #include <cstdlib>  
  3. using namespace std;  
  4.   
  5. int main()  
  6. {  
  7.     char *path="c:/renjingwei/ren/jing/wei/wo/张信哲--白月光.mp3";  
  8.     char drive[5];  
  9.     char dir[100];  
  10.     char filename[100];  
  11.     char fileext[10];  
  12.     _splitpath(path,drive,dir,filename,fileext);  
  13.     cout<<"filepath: "<<path<<endl  
  14.         <<"drive: "<<drive<<endl  
  15.         <<"dir: "<<dir<<endl  
  16.         <<"filename: "<<filename<<endl  
  17.         <<"fileext: "<<fileext<<endl;  
  18.     system("pause");  
  19.     return 0;  
  20. }  
  21. 路径分割_splitpath_s

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-05-20
  • 2022-01-07
  • 2021-11-08
  • 2021-09-13
  • 2022-12-23
  • 2021-09-27
猜你喜欢
  • 2021-07-29
  • 2022-12-23
  • 2021-07-14
  • 2022-12-23
  • 2022-12-23
  • 2021-04-27
  • 2021-12-26
相关资源
相似解决方案