Error while using Package RDCOMClient to retrieve data from Microsoft outlook

I am trying to extract data from Outlook emails using package RDCOMClient, I downloaded the package as .zip file from I am using R version 4.0.2.

I wrote below code


working_dir<- getwd()

outlook_app <- COMCreate("Outlook.Application")

But I got an error as following

Error: Invalid class string In addition: Warning message: In getCOMInstance(name, force = TRUE, silent = TRUE) : Couldn't get clsid from the string

I am not able to figure out what is the issue.

Thank you in advance for your support.