dcsimg
December 5, 2016
Hot Topics:

Referencing an Object

  • November 19, 2002
  • By Neil Avent
  • Send Email »
  • More Articles »

I am going to try and summarise all this as much as possible but a lot of ground has been covered in this article. Whether you fully understand what I have done and why I have done it comes down to how you perceive what an Object is and what you can do with it.

For those of you who have not tried anything like this before, then the idea of actually creating an instance of Internet Explorer as an object instead of a new task may be quite alien. But if you sit back and look at the reasoning and benefits gained it should begin to make sense. The principles given here can be applied to many other applications or objects. The main points you should take away from this article are the difference between Early and Late binding and closing the object properly.

Just to bring the point home again, Early Binding is where you declare what type of object you wish to create rather than just an object waiting to see what it is set to before knowing what shape to take. You will know if you have a successfully created Early Binding between the object and your project because Events will be available if you declared WithEvents and you will have the Methods, properties and constants available to you whilst in the code window.

I have never come across a situation where I have needed Late Binding (someone is bound to prove me wrong here!) and in larger projects you lose so much efficiency and speed it is not worth it.

In the next article we will be examining the Word Object Library and using it to create something with some use. It is not that hard to add a text box and use it to navigate your InternetExplorer class. Have a go at doing that and play with some of the properties, you can do some things you cannot do to it whilst it is running as a standalone application.





Page 6 of 6



Comment and Contribute

 


(Maximum characters: 1200). You have characters left.

 

 


Enterprise Development Update

Don't miss an article. Subscribe to our newsletter below.

Sitemap | Contact Us

Thanks for your registration, follow us on our social networks to keep up-to-date
Rocket Fuel