+ Reply to Thread
Results 1 to 3 of 3

trying to create a find function based on a changed cell, using VBA

  1. #1
    Registered User
    Join Date
    09-22-2016
    Location
    England
    MS-Off Ver
    2013
    Posts
    14

    trying to create a find function based on a changed cell, using VBA

    Hello.

    I am trying to combine 2 VBA codes and I am really struggling
    the following is a code to alert me whenever a value is entered into column 1 of the worksheet, i am going to change this to only trigger when the value is changed so it does not equal zero
    Capture.PNG

    the next thing i want to do is add the following function that i found online to it in order to search column 3 of the worksheet for the last cell that matches this value (EG if "A1" is entered into column A, it will search for "A1" in Column 3 and select the last result

    Capture1.PNG

    after this i am going to add an IF function that if column 4 is blank then it will paste the information from the original row into the new row (excluding columns 1 and 3) and delete the information from the original row (excluding column 3).
    if column 4 is not blank it will insert a new row afterwards and then paste all of the information into the new row (changing column 3 to the value searched for)and delete the information from the original row (excluding column 3).

    Any help with this would be greatly appreciated as I am relatively new to using Visual Basic.

  2. #2
    Forum Expert JLGWhiz's Avatar
    Join Date
    02-20-2011
    Location
    Florida, USA
    MS-Off Ver
    Windows 10, Excel 2013
    Posts
    2,070

    Re: trying to create a find function based on a changed cell, using VBA

    Try this
    Please Login or Register  to view this content.
    Instead of pasting your code as a picture, please copy it and then paste it into the thread pane, then highlight it and click the pound symbol (#) on the tool bar to add the code tags that will keep the formatting and allow it to be copied by responders.
    Last edited by JLGWhiz; 11-16-2018 at 09:20 AM.
    Any code provided by me should be tested on a copy or a mock up of your original data before applying it to the original. Some events in VBA cannot be reversed with the undo facility in Excel. If your original post is satisfied, please mark the thread as "Solved". To upload a file, see the banner at top of this page.
    Just when I think I am smart, I learn something new!

  3. #3
    Registered User
    Join Date
    09-22-2016
    Location
    England
    MS-Off Ver
    2013
    Posts
    14

    Re: trying to create a find function based on a changed cell, using VBA

    thanks for letting me know how to add code while keeping formatting. and thank you For all your help.

+ 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. Replies: 5
    Last Post: 04-11-2016, 02:48 AM
  2. How to create a timer that resets when a cell has changed.
    By Zimmerman in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-06-2016, 05:24 PM
  3. Replies: 4
    Last Post: 12-09-2014, 06:03 PM
  4. Need function to find row and column based on cell values
    By MariPip in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 10-07-2014, 04:45 PM
  5. [SOLVED] Create a macro that automates solver when a cell value is changed
    By anthony_91 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 02-22-2013, 10:45 AM
  6. Find and replace function based on first 2 characters of cell only
    By maacmaac in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-23-2012, 02:36 AM
  7. [SOLVED] Image changed based on vlookup function
    By Dave in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-11-2006, 11:10 PM

Tags for this Thread

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