开发者

Unable to create a Directory in th mapped drive

I am unable to create a directory in a mapped drive. e.g. i hav开发者_运维知识库e mapped U: to some location which there in the network. Using vc++ i am using CreateDirectory api, but it's not able to create directories. If i am giving any local machine location, it's creating. any solutions. Please let me know.

I have tried debugging my application, i find out that while running window service it's not creating but through debugging it's creating.

NOTE: the location i want to create directory have full permissions.


It looks like the drive mapping to U: is not visible from your service. That's expected, since drive mappings are usually established per-user or per-session.

However, CreateDirectory() supports UNC paths, so you can pass \\server\share\path directly instead of using a mapped drive.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜