Get MAPI Folder in Outlook from Folder Path

醉酒当歌 提交于 2019-12-01 18:14:30

I found the answer. Turns out it's something stupid, as per usual :)

Set Inbox = GetFolder("\\itadmin@email.org\inbox")

needs to be

Set Inbox = GetFolder("itadmin@email.org/inbox")

. This fixes the problem. I figured I would leave this here in case anyone else has this problem, the solution is simply to follow the given format...

Just add this line...

strFolderPath = Replace(strFolderPath, "\\", "")

Apparently also needs this line:

strFolderPath = Replace(strFolderPath, "\", "/")

But after the previous line.

So, in context:

strFolderPath = Replace(strFolderPath, "\\", "")
strFolderPath = Replace(strFolderPath, "\", "/")
标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!