LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4
Default Creating custom formulas

The answers provided to my previous post made it possible for me to obtain
the results I needed, but now I'd like to create a custom formula so I don't
have to type the whole thing out every time. In Microsoft Visual Basic I've
created a module that reads like this:

Function Commission(sales)
If sales < 150000 Then
Commission = sales * 0.0125
End If
If 150000 < sales < 200000 Then
Commission = sales * 0.0175
End If
If sales 200000 Then
Commission = sales * 0.02
End If
End Function

But when I try to insert the formula into my worksheet, it says that it
takes no argument. Help?

Thanks,
Sarah
 
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
Creating a custom formula axr0284 Excel Worksheet Functions 8 February 11th 08 12:25 PM
Creating and adding custom formulas A.R. Hunt Excel Worksheet Functions 2 March 28th 07 09:24 PM
Creating a Custom Form Shelia Excel Discussion (Misc queries) 1 December 7th 06 11:29 PM
custom lists and custom formulas? nameruc Excel Discussion (Misc queries) 0 December 6th 06 04:18 PM
Creating custom charts Taebaek Charts and Charting in Excel 1 November 27th 06 10:10 PM


All times are GMT +1. The time now is 11:36 PM.

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"