Results 1 to 3 of 3
  1. #1
    Join Date
    Mar 2017
    Posts
    2

    Unanswered: Populating Listbox from ComboBox, and Calculations

    Populating Listbox from ComboBox, and Calculations

    True Newbie here.

    I am trying to help a friend who owns rental properties without getting a bloated rental management software. I have no knowledge of SQL or programming language, so please treat me as if I am in kindergarten. Oh, I’m using Access 2003.

    I have a database simply called data for the time being. It contains a date, name, rent, and payment. Of course, it has an automatic numerical key.

    There is also a query called names that pulls a name list from the “data” file, only generating a list of the names in alphabetical order with no redundancies.

    Finally, I have a form called “payments”. It contains a combobox that generates a list of names from the “names” query. I have also added a listbox that uses the “data” query (I forgot to mention I did that query to show basically the same info as the “data” dbase. When I open it, it shows every single record in the database, and if I click on one name in the listbox, it changes the ComboBox field, which is not desired.

    My first issue – I would like to populate the listbox using the input from the combo box, which would query the database and provide only those that match the name. Ultimately, I want to generate a “balance due” from the rent and paid columns in the listbox and have that populate a “Balance Due” text box on the form, then subtract the payment amount that is input by the user to generate a “New Balance” text box on the form. Sorry, I know I’m asking a lot. Any help would be appreciated.

    I've attached a copy of what the "payment" form looks like. Hope it helps.
    Attached Thumbnails Attached Thumbnails paymentform.jpg  

  2. #2
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    630
    Provided Answers: 35
    You don't want a payment listbox, you want a SubForm.
    When you pick a client, the parent form will filter that client info,
    Thus automatically show the client payments in the subForm. (No programming for that)

    Make a single client form,
    A subForm for payments, that is put in the frmClient and
    Sync'd on the ClientID field.

    Do read about parent/child forms.
    1 to many relationships.

  3. #3
    Join Date
    Mar 2017
    Posts
    2
    Quote Originally Posted by ranman256 View Post
    You don't want a payment listbox, you want a SubForm.
    When you pick a client, the parent form will filter that client info,
    Thus automatically show the client payments in the subForm. (No programming for that)

    Make a single client form,
    A subForm for payments, that is put in the frmClient and
    Sync'd on the ClientID field.

    Do read about parent/child forms.
    1 to many relationships.
    Thank you. I will educate myself a bit more and give it a shot.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •