Results 1 to 13 of 13
  1. #1
    albertc30 is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    Sep 2011
    Posts
    11

    Question Wrong calculated VAT????

    Hello everybody.

    I am both new to the forum and to programming,database creating alltogether.

    However, I am trying to do this database for stock managment.

    My problem is the following;

    Field 1 = Cost
    Field 2 = VAT (From dropdown list)
    Field 3 = Total VAT £ [Cost]*[VAT]
    Field 4 = Total Cost [Cost]+[Total VAT]

    I have lets say an item that costs £100.00. As I have selected from the dropdown list 20% tax, it is returning me a value of £500.00????????


    Consequenteley Total Cost = £600.00.

    How come Access interprets £100.00 x 20% = £500.00?

    What am I missing here?

    Any comments/help well appreciated.

    Cheers,
    Carlos

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    What is the row source of the drop down, and the bound column?
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    albertc30 is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    Sep 2011
    Posts
    11
    Quote Originally Posted by pbaldy View Post
    What is the row source of the drop down, and the bound column?
    Hello.

    The source of the dropdown menu is a table for VAT codes with fields ID and VAT. The bound columm is the VAT one.

    I hope I have made myself clear.

    Thanks for your time.

  4. #4
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    I suspect you are dividing by .2 not multiplying by .2 to get your total VAT

    100/20% = 100/.2 = 500
    100*20% = 100*.2 = 20

    I hope you're doing this calculation in a query and not trying to store it on your table.

  5. #5
    SteveH2508 is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Sep 2010
    Location
    Chelsea, London, England
    Posts
    117
    The other possibility is that the VAT rate is stored as 20 and not .2.

  6. #6
    albertc30 is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    Sep 2011
    Posts
    11
    Quote Originally Posted by rpeare View Post
    I suspect you are dividing by .2 not multiplying by .2 to get your total VAT

    100/20% = 100/.2 = 500
    100*20% = 100*.2 = 20

    I hope you're doing this calculation in a query and not trying to store it on your table.

    Well I guess this is what happens when one don't know what to do.

    I am doing on the cell for VAT I have got: [Net cost]*[vat].

    Ang yes, I am storing this on my table.

    Again any light is well appreciated.

    Cheers.

    Carlos

  7. #7
    albertc30 is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    Sep 2011
    Posts
    11
    Quote Originally Posted by SteveH2508 View Post
    The other possibility is that the VAT rate is stored as 20 and not .2.
    Hello SteveH2508;

    I have got a VAT table where values are stored as whole numbers like;

    ID - - - - - Vat
    1 -------- 0.00%
    2 -------- 5.00%
    3 -------- 17.50%
    4 -------- 20.00%

    I have got the following for the total tax field;
    [Net cost]*[VAT]

    Forgive my ignorance but in any calculator 100 * 20.00% = 20 but not on Access which is returning me a value of 500????

    Again, I am totally new to this and I do like the challange. It would be nice to have a working stock control database.

    I know this is going to be quite a batle, there has been alote of Google already and lots of consumed time. Hopefully it will be worth it.

    Again, thanks to all of you ot there giving us a helping hand.

    All help is well appreciated.

    Kind regards,

    Carlos

    P.S: I could always ignore or just get ride of the VAT table and work with the vat % in the background. But this would be going around the problem instead of understanding it.

  8. #8
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    20% does not equal 20

    20% = .2

    If you are storing your value as 20 you would need to do something like

    [Net Cost] * ([VAT]/100)

    Do not store calculated values on your table, there's really no need to do it as long as you're storing the net cost and the tax on each record.

  9. #9
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    Can you post the db?
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  10. #10
    albertc30 is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    Sep 2011
    Posts
    11
    Quote Originally Posted by pbaldy View Post
    Can you post the db?
    Hello everybody.

    Sure thing. Here it is and please lets have all your comments either positive or negative as I have said before, I have nothing but to learn on this field of programming/databases.

    I do apologise as my knowlodge of basic rules for databases are not even with me so please, again all comments are well apreciated.

    Cheers,
    Carlos

  11. #11
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    As I mentioned, the bound column of the VAT combo box on the Items form is 1, which is the ID column, not the VAT %. The 20% VAT rate has an ID of 5, hence your problem.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  12. #12
    albertc30 is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    Sep 2011
    Posts
    11
    Quote Originally Posted by pbaldy View Post
    As I mentioned, the bound column of the VAT combo box on the Items form is 1, which is the ID column, not the VAT %. The 20% VAT rate has an ID of 5, hence your problem.
    Hello pbaldy;

    Thanks for your reply.

    I totally understand what you are saying.

    The thing now is I have looked all over for the so called 'bound column' and can't find it anywhere.

    So what I have done was I removed the ID on the VAT table and now only have one field for the vat values.

    I will have to keep on looking.

    Thanks for your help.

    Cheers,
    Carlos

  13. #13
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    The bound column is a property of the combo box. It determines which column of the row source is saved if the combo is bound, and which column is returned as the combo's value if the .Column property isn't specified.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

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

Similar Threads

  1. What's wrong!
    By khalid in forum Programming
    Replies: 15
    Last Post: 06-27-2011, 06:38 AM
  2. can't figure out what i'm doing wrong
    By m0use in forum Queries
    Replies: 4
    Last Post: 06-16-2011, 09:18 AM
  3. What is wrong with this IFF?
    By bburton in forum Reports
    Replies: 2
    Last Post: 03-16-2011, 10:42 AM
  4. What is wrong with this code?
    By nkenney in forum Forms
    Replies: 2
    Last Post: 11-16-2009, 03:04 PM
  5. What am I doing wrong?
    By brandon in forum Access
    Replies: 2
    Last Post: 08-03-2008, 10:26 AM

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