如何设置PATH在c ++中保存文件的位置 [英] how to set PATH where to save a file in c++
本文介绍了如何设置PATH在c ++中保存文件的位置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
你能帮助我如何设置c ++的路径,我可以保存用c ++创建的文件
can you help me how to set a path for c++ where i can save a file created in c++
推荐答案
你没有说你使用的是什么技术用于您的I / O操作但是
- fopen_s() [ ^ ]将目录规范作为文件名的一部分。
- CreateFile() [ ^ ]同样。
- 流接口(不同的API)都采用目录规范。
唯一不能这样做的地方是控制台输出和调试/输出窗口。
You didn't say what technology you were using for your I/O operations but
- fopen_s()[^] takes directory spec as part of the filename.
- CreateFile()[^] likewise.
- streams interface (varying APIs) all take directory spec.
The only place you can't do this is with the console output and debug/output window.
这篇关于如何设置PATH在c ++中保存文件的位置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文