• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 32. Creating Custom Functions > Creating Custom Functions with Optional...

Creating Custom Functions with Optional Arguments

Some of Excel's built-in functions let you omit certain arguments. For example, if you omit the type and future value arguments from the PV function, Excel still computes the result because those arguments are optional. Your custom functions can also make use of optional arguments.

For example, suppose you want to create a custom function called RightTriangle that uses the Pythagorean theorem to compute the length of any side of a right triangle given the lengths of the other two sides. The equation that expresses the Pythagorean theorem is a2 + b2 = c2, in which a and b are the short sides and c is the hypotenuse. Given any two sides, you can use this equation to solve for the third side.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint