Dave Peterson wrote:
> Are you sure you loaded myAddin.xla?
>
Absolutely.
The runtime error only occurs, if the function should return an object type.
>
>
> Robert Schwenn wrote:
>> Dave Peterson schrieb:
>>> First, if you use application.run, you don't need a reference to that other
>>> addin's project.
>>>
>>> Second, you can create a function in the addin that returns an object. Then you
>>> can call that function.
>> Ok, I was wrong: You *can* return an object by the function.
>>
>> Thats why the next question: This works inside Excel. But when I run the
>> function from a vbscript (that is what I want), I get a runtime error, if the
>> function returns an object (other return types are ok):
>>
>> set xl = CreateObject("Excel.Application")
>> set dummy = xl.Run("myAddin.xla!fct_name", arg1, arg2) 'runtime error
>>
>> Robert
>>
>>> Robert Schwenn wrote:
>>>> Hi,
>>>>
>>>> in a thread a few days ago we saw, that a function of another add-in can be
>>>> called (without a reference to that add-in) in this way:
>>>>
>>>> s = Application.Run("myAddin.xla!fct_name", arg1, arg2)
>>>>
>>>> But how can be gained access to a public object variable of another plugin?
>>>> (It seems, that there cannot be returned an object via Application.Run)
>>>>
>>>> Robert
>
|