Results 1 to 3 of 3
  1. #1
    burrina's Avatar
    burrina is offline VIP
    Windows 7 64bit Access 2002
    Join Date
    Oct 2012
    Location
    Freeport,Texas
    Posts
    1,383

    If IsNull Value, Then need to be Zero

    I am trying to calculate payments from a subform and then have them subtracted from the total on my main form.
    Main form name is OrderDetails, subform is named OrdersPaymentSub

    1. =[txtOrderSubtotal]+Nz([FreightCharge])+Nz([Taxes])-[txt102] ' txtOrderTotal Minus Sum of Payments,i.e. txt102
    2. =TPaymentSub.Form!SumPayment ' Sum of Payments on subform. Default value is 0

    1. equals the total on main form minus the sum of payments on the subform.


    2. equals the sum of payments on the subform

    Problem is that if NO payments are made, it makes my formula not work.
    1. main form will have no value from subform

    I have tried the Nz thing with no success.
    Such as =Nz([txt102],0)

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,628
    I can't replicate the issue. If you want to provide db for analysis, follow instructions at bottom of my post.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    burrina's Avatar
    burrina is offline VIP
    Windows 7 64bit Access 2002
    Join Date
    Oct 2012
    Location
    Freeport,Texas
    Posts
    1,383
    If you would personally look at it then I would not mind sending,otherwise I regress but to send a scaled down version.
    I am still a little ways off from being done. Reports are giving me fits.I have sorted out the Labels and messages. I am a little concerned about my structure, if I have it right.Everything seems to be working ok. I will get back with you no doubt soon.

    Thanks s much for all you help.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. IsNull not working
    By vbjohn in forum Access
    Replies: 19
    Last Post: 02-29-2012, 02:21 PM
  2. IsNull
    By JJCHCK in forum Programming
    Replies: 3
    Last Post: 09-09-2011, 07:57 AM
  3. dcount and isnull
    By Madmax in forum Access
    Replies: 7
    Last Post: 06-22-2011, 09:31 AM
  4. IsNull not working...
    By Moekandu in forum Programming
    Replies: 3
    Last Post: 01-29-2011, 06:48 PM
  5. IsNull question
    By Simon Sweet in forum Access
    Replies: 4
    Last Post: 12-22-2007, 04:33 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums