我如何使用Boost.Filesystem更改当前路径
|
启动程序时,我想使用current_path()(\“ C:\\ workspace \\ projects \”)打印当前路径。然后,我希望能够将路径更改为\“ c:\\ program files \”,所以当我再次打印current_path()时,我想将其打印为“ c:\\ program files \” 。像这样
int main()
{
cout << current_path() << endl; // c:\\workspace\\projects
aFunctionToChangePath(\"c:\\program files\");
cout << current_path() << endl; // c:\\program files
}
库中是否缺少我可以完成的功能?
没有找到相关结果
已邀请:
2 个回复
厦惫
澳绍能