Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 18
Default Function prototypes in Excel VBA

Dear Excel VBA Gurus,

Is there any function prototypes equivalent in Excel VBA as there are in C
language?

Function prototypes are useful because it allows the programmer to see what
are the functions implemented in a file at the top.


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default Function prototypes in Excel VBA

No, there are not.

--
Regards,
Tom Ogilvy


"Sing" wrote:

Dear Excel VBA Gurus,

Is there any function prototypes equivalent in Excel VBA as there are in C
language?

Function prototypes are useful because it allows the programmer to see what
are the functions implemented in a file at the top.



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,600
Default Function prototypes in Excel VBA

Maybe(?) look at the two drop downs at the top of modules in the VBE.

For more info, arguments etc -
select your project in the left panel
F2 Object Browser
in libraries (the top drop down) select your project name.

Regards,
Peter T


"Sing" wrote in message
...
Dear Excel VBA Gurus,

Is there any function prototypes equivalent in Excel VBA as there are in C
language?

Function prototypes are useful because it allows the programmer to see

what
are the functions implemented in a file at the top.




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default Function prototypes in Excel VBA

Peter,
In my experience, C function prototypes show how the function is calculated
- not what the inputs are. There is no equipvalent in VB or VBA unless you
know something else.

--
regards,
Tom Ogilvy


"Peter T" wrote:

Maybe(?) look at the two drop downs at the top of modules in the VBE.

For more info, arguments etc -
select your project in the left panel
F2 Object Browser
in libraries (the top drop down) select your project name.

Regards,
Peter T


"Sing" wrote in message
...
Dear Excel VBA Gurus,

Is there any function prototypes equivalent in Excel VBA as there are in C
language?

Function prototypes are useful because it allows the programmer to see

what
are the functions implemented in a file at the top.





  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,600
Default Function prototypes in Excel VBA

Thanks for that Tom,

unless you know something else.


Nope !

Regards,
Peter T


"Tom Ogilvy" wrote in message
Peter,
In my experience, C function prototypes show how the function is

calculated
- not what the inputs are. There is no equipvalent in VB or VBA unless

you
know something else.

--
regards,
Tom Ogilvy


"Peter T" wrote:

<snip




  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 417
Default Function prototypes in Excel VBA

My quick search of the web gave several examples similar to the following:

float doubleIt(float inVal);

...which is effectively just the top line of code of the routine, which
lists the arguments, their return types, and the return type of the
routine. The Object Browser in VBA would essentially perform the same
functionality.

I think you would have to have a flowchart (and possibly diagrams, like
data flow and/or event flow) to show the algorithm of how a function is
calculated.
--
Regards,
Bill Renaud



  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 417
Default Function prototypes in Excel VBA

Is your question really about "header files"? VBA does not use header files
(that list all functions, their arguments, return types, etc.), because
this is just extra work for the programmer and can lead to errors. In C, if
a programmer changes the main code file, and forgets to change the header
file, then a compile error results.

In VBA, you open up the project that has the routines that you want to
inspect, then go into the Object Browser (<F2 key in the VBA Editor),
select the Library in the Library drop-down combo box, then inspect the
methods and properties, as mentioned in a previous post by Peter T.

--
Regards,
Bill Renaud



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
Excel Data Validation/Lookup function does function correcty Kirkey Excel Worksheet Functions 2 May 25th 09 09:22 PM
copy of excel file not showing formulal/function in the function b oaallam Excel Discussion (Misc queries) 4 September 6th 07 01:20 PM
Excel - User Defined Function Error: This function takes no argume BruceInCalgary Excel Programming 3 August 23rd 06 08:53 PM
Adding a custom function to the default excel function list DonutDel Excel Programming 3 November 21st 03 03:41 PM
When I Import an Access Table With an Excel Function in a Cell it Displays as Text not as a Function in Excel Niek Otten Excel Programming 2 September 18th 03 03:55 AM


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

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

About Us

"It's about Microsoft Excel"