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: 26
Default Request help with Arithmentic UDF

Please tell me why this isn't working.

Function SumInvoice(myC As Range) As Long
Dim Est As Long
Dim Fore As Long
Dim Prev As Long

Est = myC.Offset(0, 3).Value + Cells("K134")
Fore = myC.Offset(0, 4).Value + Cells("K135")
Prev = myC.Offset(0, 5).Value + Cells("K136")

If myC.Cells.Text < "Z*" Then
SumInvoice = 0

ElseIf Est 0 Or Fore 0 Then
SumInvoice = (Est + Fore) - Prev

Else: SumInvoice = 0

End If
End Function
 
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
Request for Help [email protected] Excel Programming 3 July 11th 07 05:45 PM
Request Barry Excel Discussion (Misc queries) 1 January 5th 07 06:20 AM
sql.request teepee Excel Discussion (Misc queries) 2 December 30th 05 01:34 PM
Request .. debra2468[_9_] Excel Programming 1 August 4th 04 09:23 PM
Add-on to last request Pepe[_2_] Excel Programming 0 January 15th 04 02:25 PM


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