In a nutshell, late binding is not declaring your objects at design
time, rather you let them be resolved at runtime. It's therefore written
in the code and so whether or not the OCX is referenced in the VBA
project is not important: if you use late binding - it's irrelevant.
(That's not very clear is it!)
Normally early binding is better and faster, as in your original post:
Dim SH As IWshRuntimeLibrary.WshShell
Set SH = New IWshRuntimeLibrary.WshShell
rather than late binding (from Dave Peterson's email)
Dim SH As Object
Set SH = CreateObject("wscript.shell")
But occasionally late binding can be useful - for example here Dave was
hoping it might fix your problem. (Which appears to be insolvable.)
Take a look at CreateObject Function in VBA Help for more info on late
and early binding.
With respect to your OP - I think the consensus is to go with userforms!
HTH
R.VENKATARAMAN said:
apologise for asking a dumb question. what is late binding. what should I
do.
I removed the tick from the reference list.
still sub stops at
Res=etc. etc..
error
<named argument not found>
================================