Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default TypeLib Information Problem? Pass a Function's parameter names as string for parsing?

I am trying to build a wizard with a form based GUI to facilitate the
use of functions supported by an excel add-in. Each function has a set
of required parameters. I will use a text box on the form for the user
to input each value to be passed to the parameters of the addin
function. Is it possible to interrogate the addin to have an array
returned telling me the required parameters? In the same way that the
object explorer can tell you e.g.,

Function AddInFunction(Parameter1 As Long, Parameter2 As Date,
[Parameter3 As Date])

Member of MyAddin.Main

Just to be able to assign that lot to a string variable would be
awesome. The idea being that my addin wizard would be flexible to any
changes made to the addin. From reading prior posts it seemed like
this might be possible using a TypeLib API method. However when I run
the necessary code on the MyAddin.xla file itself I get an error
saying the file doesn't contain a valid TypeLib. The addin does ship
with a library file but this seems to list only the activex functions
called by the addin and not the functions the addin offwers that act
as a wrapper to these active-x calls. Am I trying to do something that
is not possible?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 691
Default TypeLib Information Problem? Pass a Function's parameter names as string for parsing?

Hi Ali,
You might build it into the your add-in so one can key in "Help"
for the first parameter. Make all of your parameters optional.
It is best to name your parameters so that you know what is
wanted as Excel does not provide decent facilities for describing
each parameter of user defined functions.

See http://www.mvps.org/dmcritchie/excel...ll.htm#fundesc

Laurent Longre has information on adding descriptions for parameters,
his site is in French. This particular on is probably one is in English.
http://longre.free.fr/english/
---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"Ali G" wrote in message om...
I am trying to build a wizard with a form based GUI to facilitate the
use of functions supported by an excel add-in. Each function has a set
of required parameters. I will use a text box on the form for the user
to input each value to be passed to the parameters of the addin
function. Is it possible to interrogate the addin to have an array
returned telling me the required parameters? In the same way that the
object explorer can tell you e.g.,

Function AddInFunction(Parameter1 As Long, Parameter2 As Date,
[Parameter3 As Date])

Member of MyAddin.Main

Just to be able to assign that lot to a string variable would be
awesome. The idea being that my addin wizard would be flexible to any
changes made to the addin. From reading prior posts it seemed like
this might be possible using a TypeLib API method. However when I run
the necessary code on the MyAddin.xla file itself I get an error
saying the file doesn't contain a valid TypeLib. The addin does ship
with a library file but this seems to list only the activex functions
called by the addin and not the functions the addin offwers that act
as a wrapper to these active-x calls. Am I trying to do something that
is not possible?



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
use function to change a string to function's parameter ViestaWu Excel Worksheet Functions 3 November 21st 07 12:42 PM
How to: Pass Command Line Parameter ??? Webtest Excel Worksheet Functions 0 October 24th 05 05:27 PM
How to pass a workshhet name as a parameter into a subroutine ? yigalb Excel Discussion (Misc queries) 4 January 9th 05 10:28 AM
Pass string as Parameter in OpenText method No Name Excel Programming 0 January 8th 04 06:22 AM
How do I change a function's otional parameter default values programmically Michael[_21_] Excel Programming 5 October 24th 03 09:22 PM


All times are GMT +1. The time now is 08:04 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"