2011-06-03 48 views

回答

4

如果确实是文件系统路径,请致电ILCreateFromPath。如果您还需要处理非文件系统对象(如“我的电脑”或“网上邻居”),请使用SHParseDisplayName

+0

谢谢,完美的作品。我知道SHParseDisplayName,但行为过于“松散”(除了shell命名空间扩展,它接受本地化文件夹等) – 2011-06-03 13:17:50

+0

请检查[后续问题](http://stackoverflow.com/questions/6227806/ on-ilcreatefrompath-and-error-checking),谢谢! – 2011-06-03 13:41:29

+0

'SHParseDisplayName()'优于'ILCreateFromPath()'(Mirosoft说尽可能多)。 – 2011-06-04 07:26:06