Excel functions, although rich, do not meet all of our needs. We can customize a function to perform some specific operations. Below, we will come from the definition of a function to compute the trapezoidal area:
1. Execute the tools → macros →visual basic Editor menu command (or press the "ALT+F11" shortcut key) to open the Visual Basic editing window.
2. In the window, execute the Insert → module menu command and insert a new module-Module 1.
3. In the Right code window, enter the following code:
Function V (a,b,h) v = h* (a+b)/2end function
4. Close the window and complete the custom function.
You can use custom functions in the future just as you would with built-in functions.
Tip: Functions that are customized with the above method are usually available only in the appropriate workbook.