如何以effceint方式查找最后创建的目录. [英] How find the last created directory in effceint way.

查看:67
本文介绍了如何以effceint方式查找最后创建的目录.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好我的问题可能很简单,但是我没有得到正确的答案.问题是我什么时候通过类似
的代码创建目录

Hi my question may be simple but i am not getting the right answer for it.Well the question is When ever i create directory through code like

int nRslt = ::CreateDirectory(L"\MyPathName",NULL);//It will create the folder in working drive.
if(nRslt == 0)
	{
	   ::AfxMessageBox(_T("Wrong name"));
	}
        else
       {
nRslt = ::CreateDirectory(L"MyPathName",NULL);//It will create the folder in application folder.
if(nRslt == 0)
	  {
	    ::AfxMessageBox(_T("Wrong name"));
	  }
       }



现在我只想问一问,在 CreateDirectory()函数被调用之后,如何获取在目录/文件夹创建位置的信息.任何其他类型的帮助都是有益的.

谢谢
:D为目前的生活就像共同基金" :D



Now I just want to ask How can i get the information where the directory/folder is created just after the CreateDirectory() function being called.any other kind of help is beneficial.

Thank you
:D Cheers for the present "Life is like mutual fund" :D

推荐答案

欢呼.使用CreateDirectory()方法创建文件夹后,您可以在文件夹名称的帮助下获取文件的完整路径.您可以根据需要使用GetShortPathName(),GetLongPathName()和GetFullPathName().
After you create the folder using CreateDirectory() method, you can get the full path of the file with the help of folder name. You can use GetShortPathName(), GetLongPathName() and GetFullPathName() depending upon your requirement.


这篇关于如何以effceint方式查找最后创建的目录.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆