LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default How do I change a function's otional parameter default values programmically

I wrote a function in VBA that has two required parameters and two
optional parameters (which have default values set to defined
constants). I want to be able to have the user open a form that lets
them change the optional parameters default values, then store these
values in a table in the spreadsheat.

The problem is trying to get these values from the spreadsheet to the
optional parameter default values. If I read the optional default
values in from the spreadsheet, I have to redefine the default
constants as variables, and when I try to compile the code, I get
"Compile Error: Constant Expression Required", (which references the
optional paramter defaults in the function).

Any ideas on how to allow the user to change these optional parameter
default values without going into the VBA code?

~Michael
 
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
Default Cell Values at Change TheDrescher Excel Worksheet Functions 2 April 28th 10 04:41 PM
Pick up values by parameter Matti Koski Excel Worksheet Functions 0 April 7th 08 09:53 AM
Parameter Query to return multiple values Ruth Excel Discussion (Misc queries) 2 January 3rd 08 12:50 PM
use function to change a string to function's parameter ViestaWu Excel Worksheet Functions 3 November 21st 07 12:42 PM
Creating Variables Programmically Brite Excel Discussion (Misc queries) 5 April 23rd 07 10:34 AM


All times are GMT +1. The time now is 08:11 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"