View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
LLT LLT is offline
external usenet poster
 
Posts: 5
Default XLL Functions from Excel VBA

Hi,

I am trying to call a function in an installed XLL addin in excel. Unless I
declare the function, I cannot use it.

If I use this declaration:
Declare Function EssVDisconnect Lib "ESSEXCLN.XLL" (ByVal SheetName As
Variant) As Long
and call:
EssVDisconnect "SheetName"
it works.

But if I try to use it this way (without a declaration), it doesn't work:
Application.Run "ESSEXCLN.XLL!EssVDisconnect", "SheetName"

Can someone explain if it is required for calling XLL functions from VBA to
always Declare their functions?

Thanks,

Leo