Is their a way to check an application exists before I write in the code to create the object
I know this is install and I can use it but what if I want the program to check first ?
Set objOutlook = GetObject("Outlook.Application")
Is their a way to check an application exists before I write in the code to create the object
I know this is install and I can use it but what if I want the program to check first ?
Set objOutlook = GetObject("Outlook.Application")
In fact, you should verify if there is entry in Registry. You can proceed as follows;
Dim regKey As RegistryKey
regKey = My.Computer.Registry.ClassesRoot.OpenSubKey("Outlook.Application", False).OpenSubKey("CurVer", False)
If not string.IsNullOrEmpty(regKey.GetValue("")) then
// Your code
End if