Results 1 to 3 of 3
  1. #1
    Lounger
    Join Date
    Jan 2001
    Posts
    39
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Auto update of quantity (2000 SR-1)

    I want to create a database in which I have a table with starting inventories of say 6 items. I want to be able to enter in a form what day, what item and how many of said items were taken to be shipped out. For the life of me I can't figure out how to do this. An expression like QOH: [Inventory]-[itemqnty] is useless as it doesn't update the inventory field to reflect some were taken out.

  2. #2
    4 Star Lounger
    Join Date
    Feb 2001
    Location
    Richland, Washington, USA
    Posts
    407
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Auto update of quantity (2000 SR-1)

    If all you want to keep in the table is the current inventory amount, then bind the form to this table (specify this table as the form's record source). Include in the form a control (locked for editing) that shows the current inventory of the selected item (i.e., this control should be bound to the table value). Include an unbound control in the form for the quantity removed from inventory. In this control's AfterUpdate event, update the bound current inventory control. Something like:
    <font face="Georgia">
    Private Sub txtQtyRemoved_AfterUpdate()

    Me!txtCurrentInventory = Me!txtCurrentInventory - Me!txtQtyRemoved

    End Sub
    </font face=georgia>
    Hope this helps.

  3. #3
    Lounger
    Join Date
    Jan 2001
    Posts
    39
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Auto update of quantity (2000 SR-1)

    Will give it a try, thanks!

Posting Permissions

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