Open .msg file + convert to .pdf

luksim

New Member
Hello guys,

I need to open .msg file and convert it to .PDF format. I know that when open, we can send keys CTRL+P to save as .pdf.
Has anyone done the code for opening .msg format file?

//Lukas
 

ShubhamJangam

New Member
Hi,
Check if this works for you.

If your .msg file is saved locally.
Utility Environment - Start Process can be useful.
Application Name - Outlook exe path
Argument Name - msg file path

this will opens msg file and you can use CTRL+P

Thanks
 

MGagarin

New Member
Hello Luksim,
I know that this post is way back now but just curious how you able to do this using Shubham's suggestion. I tried the Start process pointing to the Outlook.exe path and the Argument pointing to the .msg file path but not working giving me error "Command line argument is not valid. Verify the switch you are using"
Once I removed the Argument value, it will open the Outlook without error. It doesn't like the value in the Argument whic supposed to be the .msg file and path
Can you share your logic ? Goal here is to open .msg and then will use key (Control-P) to print (set my default to Microsoft Print to PDF)
Or did you use different logic/approach? Do you mind sharing?
Thanks,
Marilyn
 
Top