+ Reply to Thread
Results 1 to 6 of 6

Updating stock with macro

  1. #1
    Registered User
    Join Date
    10-26-2007
    Posts
    4

    Updating stock with macro

    Ok, I have a sheet which holds all my stock items with the amount. And on a seperate sheet a simple form.
    I will try to explain the problem with an example.

    On the form it will have (sheet 1)
    ID:10002
    Amount: 7
    >button with macro asgined<

    On sheet 2, where stock levels are stored.
    ID:10002
    Amount: 13

    I need the form to lookup the ID number the user has enterd, then find it in sheet 2 and change the amount of that entry. So 13+7.

    Any help would be much appreciated.

  2. #2
    Forum Contributor
    Join Date
    08-10-2006
    Posts
    723
    hi,

    would it not be easier to use a pivot table ?

    steve

  3. #3
    Valued Forum Contributor mudraker's Avatar
    Join Date
    11-10-2003
    Location
    Melbourne, Australia
    Posts
    3,983
    Mekanto

    Please read forum rules

    Questions relating to macro's belong in the Programming Forum

    A thread with the rules is available at the top of each forum or see link below for rules
    Please Read Forum Rules Before Posting
    Wrap VBA code by selecting the code and clicking the # icon or Read This
    How To Cross Post politely

    Top Excel links for beginners to Experts

    If you are pleased with a member's answer then use the Scales icon to rate it
    If my reply has assisted or failed to assist you I welcome your Feedback.

  4. #4
    Registered User
    Join Date
    10-26-2007
    Posts
    4

    Updating stock with macro

    Ok, I have a sheet which holds all my stock items with the amount. And on a seperate sheet a simple form.
    I will try to explain the problem with an example.

    On the form it will have (sheet 1)
    ID:10002
    Amount: 7
    >button with macro asgined<

    On sheet 2, where stock levels are stored.
    ID:10002
    Amount: 13

    I need the form to lookup the ID number the user has enterd, then find it in sheet 2 and change the amount of that entry. So 13+7.

    Any help would be much appreciated.

  5. #5
    Forum Contributor
    Join Date
    11-11-2005
    Posts
    267
    Use VLookUp which in VBA is Application.VLookUp(your arguments)
    HTH
    Myles

    ...constantly looking for the smoother pebble while the whole ocean of truth lies before me.

  6. #6
    Forum Contributor
    Join Date
    08-10-2006
    Posts
    723
    hi,

    do you want to keep a record of all your transactions, and what date that transaction took place. what happens when you remove that part from stock.

    steve

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1