Results 1 to 8 of 8
  1. #1
    erickemboi is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Sep 2020
    Posts
    73

    Add a value to subcategories of drop down menu

    I have the following categories


    1. Beverages. Price
    i. Tea-
    ii. Coffee-.
    iii. Cocoa-
    I would like the user of database to select from beverages probably tea or coffee or cocoa drop-down (list box) and allow him to add the price.
    N.b- datafield for price should be number
    Thanks in advance

  2. #2
    Join Date
    May 2018
    Location
    Living in Scotland UK
    Posts
    1,557
    Hi

    First of all you need 2 tables to manage this process.

    tblCategories
    -CategoryID - PK - Autonumber
    -Category (Lists all of the categories you deal with. ie Beverages, Hams, Vegetables)

    tblCategoryItems
    -CategoryItemID - PK - Autonumber
    -CategoryID - FK - Number - (Linked to PK from tblCategories)
    -CategoryItem - Text

    Once you have these two tables in place you would then create a Main Form based on tblCategories
    Then create a Subform based on tblCategoryItems
    You would link Parent/Child on CategoryID

    Then you would be able to manage the process you asked the question about.
    You can PM me if you need further help.
    Good Reading https://docs.microsoft.com/en-gb/off...on-description

  3. #3
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,737
    IMO, depends on how complicated you want to make it. If you don't mind the fact that you will never be able to group by category then it's not required. That being said, it also depends on what you mean by "add the price". Once so that it can be referred to from then on, or this is for orders, so once per item per order? I probably would not do the latter unless you want to be able to fluctuate the price per item per order. Even then, it might be better to apply a discount to a static price.

    Basically, you can't add column data to a combo in whatever column you please. You would need a textbox on your form and update the price field in the record where the combo value is the same. Once you save the price, the combo can show it as long as that field is part of the combo rowsource and there is a combo column for it.
    Last edited by Micron; 09-14-2021 at 09:28 AM. Reason: added info
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  4. #4
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,737
    speaking for myself:

    @erickemboi
    - please first make your requests for db samples in your posts, not via PM or someone's message board
    - post what you have already. If nothing, make something with a table(s) with data and any forms/queries/reports you need to accomplish that. I'm not here to do all the work for you unless (maybe) you're paying for it.
    - perhaps most importantly, when someone makes points in a post and you don't answer them, don't expect too much.
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  5. #5
    erickemboi is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Sep 2020
    Posts
    73
    Thanks sir. I would really appreciate if there were db samples. Thanks in advance sir

  6. #6
    Join Date
    May 2018
    Location
    Living in Scotland UK
    Posts
    1,557
    Hi
    The idea is that you create the tables
    You can PM me if you need further help.
    Good Reading https://docs.microsoft.com/en-gb/off...on-description

  7. #7
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,737
    Quote Originally Posted by mike60smart View Post
    Hi
    The idea is that you create the tables
    And everything else that would be needed.
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  8. #8
    erickemboi is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Sep 2020
    Posts
    73
    Thanks so much

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

Similar Threads

  1. Replies: 1
    Last Post: 08-15-2019, 12:22 PM
  2. Alphabetical Drop Down Menu
    By OzGrant in forum Access
    Replies: 1
    Last Post: 03-15-2015, 02:58 AM
  3. Drop Down Help Menu
    By dandoescode in forum Access
    Replies: 1
    Last Post: 08-07-2012, 02:51 AM
  4. Drop down menu help
    By whojstall11 in forum Access
    Replies: 6
    Last Post: 03-07-2012, 01:51 PM
  5. Replies: 3
    Last Post: 11-29-2011, 07:01 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