+ Reply to Thread
Results 1 to 5 of 5

userform update table based on 3 criteria

  1. #1
    Forum Contributor
    Join Date
    04-05-2013
    Location
    CT
    MS-Off Ver
    Excel 2010
    Posts
    360

    userform update table based on 3 criteria

    I use the following code to look up a value based on 3 fields (job number, month, year)

    Please Login or Register  to view this content.
    this will pull up the $value that matches that criteria. I would like to then be able to modify that value and UPDATE the value in the table . So basically it has to perform the same function but then enter the value within the "billingamount" text box.

    any help is appreciated. thanks!
    Last edited by adamheon; 12-29-2016 at 04:43 PM.

  2. #2
    Forum Guru bakerman2's Avatar
    Join Date
    10-03-2012
    Location
    Antwerp, Belgium
    MS-Off Ver
    MSO Home and Business 2024
    Posts
    7,338

    Re: userform update table based on 3 criteria

    There may be better solutions but what I do in a case like this is add an extra column to the Listbox, fill it with the rownumbers of every record, then filter and afterwards you can use this number in yours Cells-statement to find correct row.
    Would be something like.

    Please Login or Register  to view this content.
    To update ListBox code post example file with exact layout of your original file.
    Avoid using Select, Selection and Activate in your code. Use With ... End With instead.
    You can show your appreciation for those that have helped you by clicking the * at the bottom left of any of their posts.

  3. #3
    Forum Contributor
    Join Date
    04-05-2013
    Location
    CT
    MS-Off Ver
    Excel 2010
    Posts
    360

    Re: userform update table based on 3 criteria

    Here is a sample file.

    That makes sense what you're saying...but i'm not familiar with listbox's, so not quite sure how to adjust for that. Thanks for the help.
    Attached Files Attached Files

  4. #4
    Forum Guru bakerman2's Avatar
    Join Date
    10-03-2012
    Location
    Antwerp, Belgium
    MS-Off Ver
    MSO Home and Business 2024
    Posts
    7,338

    Re: userform update table based on 3 criteria

    This should do it.
    Attached Files Attached Files

  5. #5
    Forum Contributor
    Join Date
    04-05-2013
    Location
    CT
    MS-Off Ver
    Excel 2010
    Posts
    360

    Re: userform update table based on 3 criteria

    That worked perfect! thank you!

    Is there a way to set the format of billingamount to accounting format?

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Userform to Update Table Values based on a Listbox Selection
    By scottkelley80 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 12-27-2016, 08:49 PM
  2. [SOLVED] Userform to Update Table
    By adamheon in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-17-2016, 12:15 PM
  3. update table based on the selection in userform
    By melody10 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 08-15-2015, 11:25 AM
  4. Trying to update an access table from Excel based on unique ID. rst.Update not working
    By Newbie0924 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-22-2015, 04:15 PM
  5. Update excel based on userform text box update
    By sivakumar123 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-11-2013, 01:01 AM
  6. Update table from a userform with controls
    By mohanvp in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-26-2011, 03:56 AM
  7. Macro code to update Pivot table based on criteria
    By wish2excel in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 09-30-2010, 05:44 AM

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