I have a a ton of PSTs and I need to be able to open them and get their metadata (Sender, date, time, message, subject). I tried using code found here - Can I read an Outlook (2003/2007) PST file in C#?
I get an error when it gets to the line:
MAPIFolder rootFolder = outlookNs.Stores[pstName].GetRootFolder();
It doesn't like what I have for my pst name.
I'd like to just be able to loop through all my psts without worrying what the file path and file name is. Is this possible?
Edit: If it is possible, I'd like to eventually put it into a SQL database, but even a flat file (CSV or even XML or whatever else) will do.