Hi guys

Is there a way to change reference at runtime ?

I am automating Word from VB.Net. I think what I have coded will be same for both Word2003 and Word2007. I used Word 12 Object Library reference(which is of Word2007).

So, I want to know how to make it compatible with a machine installed with Office2003. That is, it will check the whether the machine has 2003 installed. If so, use that reference. Otherwise use 2007.

I think the Word object has an Application.Version property which would return the version of the currently installed the Word and can be used to check the version.

I know about late binding, which is a bit tough as it has more overheads. I am currently using early binding.

Any ideas ?

Thanks