"items As Outlook.items" - convert to late binding

Isaac

Lifelong Learner
Local time
Today, 02:41
Joined
Mar 14, 2017
Messages
11,421
Code:
items As Outlook.items

What is the truly Correct conversion to late binding? Would it be a collection? Not an object, right? Or do you also declare it as Object?
 
Try using "Object." It's the most basic type.
 
You declare things as objects. Then assign a specific type of object to them. The real pain of late binding is the lack of constants. You have to declare all the constants you need and use yours rather than the ones that would have been supplied with intellisense using early binding.
I agree, it is a pain. For example I have to replace excel's xlUp with -4162 (or something like that).
I wasn't sure if in some cases you might declare a collection of stuff as a collection or if it was 100% as objects....I guess it's 100% as objects.
Although I had done this exercise many times, I'd never converted Outlook.Items before and wasn't totally certain.
 

Users who are viewing this thread

Back
Top Bottom