PDA

Click to See Complete Forum and Search --> : Early vs Late binding


badgers
Dec 28th, 1999, 09:05 PM
I had recieved help on this board that showed me how to use the spell check in word for a text box. I believe the code given to me uses late binding. Is it possible to use early binding?(not the complete code just what I think to be late binding)

Dim Word As Object, retText$
Set Word = CreateObject("Word.Basic")
Word.AppShow

if this is late binding, can early binding be used and how does early binding work?



------------------
I am so skeptacle, I can hardly believe it!

joey o.
Dec 28th, 1999, 09:49 PM
Funny, I was asked this question on an interview! To the best of my knowledge it's late binding and just by referring to the object through the object browser it's available. Early binding is creating the object from scratch (I think). I'm still a new-be and I look forward to someone clarifying this further.
Joey O.

Clunietp
Dec 29th, 1999, 12:09 AM
I have posted a similar response here:
http://www.vb-world.net/ubb/Forum1/HTML/012324.html

badgers
Dec 29th, 1999, 12:59 AM
RogerH:
OK it opens up word.
how can I tell it to open up a document for me? Is there a help file or a website that will help. The intellisense is not very intelligent for me.
thank you for your time and have a good day


------------------
I am so skeptacle, I can hardly believe it!

badgers
Dec 29th, 1999, 01:42 AM
never mind I found how to open a document

RogerH
Dec 29th, 1999, 11:52 AM
Sorry, but there's an essential diff between late and early binding!

Select in menu Project - References the "MS Word Object library". Your code with early binding:

Dim objword As word.Application
Set objword = New word.Application
objword.Visible = True

Benefits: Faster and IntelliSense (the function that shows you possible parameters and so on while you're writing the code)

RogerH