+ Reply to Thread
Results 1 to 4 of 4

Need help with code in If statement for pasting entries into another sheet

  1. #1
    Registered User
    Join Date
    06-13-2016
    Location
    NJ
    MS-Off Ver
    2010
    Posts
    95

    Need help with code in If statement for pasting entries into another sheet

    Hi,

    Im creating a new sheet in a spreadsheet that I have already made and seeked help on here for.

    The file is attached. The question i have pertains to sheet 4 and 5, the two wishlist sheets.

    The code I have is copied from the code for the Add Data macro in the add request sheet. You can run it to understand what Im saying.

    Basically the existing code was used to match the broker name in column A in sheet "add request" and paste the information in the top (B1:B5) to the matched column B in the sorted by broker sheet. Try it for yourself

    Now what I need help with:

    In the wishlist sheets its a similar idea except the broker might not exist yet in the "Wishlight - Brokers" sheet column B. So its first assessing whether the broker listed in sheet "Add Wislist" Column A exists or not and if it doesnt then paste the broker name and the info from B3:B5. If it already exists and can be matched in Column B in "wishlist - brokers" then do what the macros is already doing and duplicate the information in B3:b5 in "Add Wislist" for a row beneath the broker name in "Wishlight - Brokers"

    Here is the code i have. The code assumes that the Broker is already listed and that is what I am trying to fix, adding the additional if statement for when it is not listed


    Please Login or Register  to view this content.
    Im just not too sure what that coding is or if other things need to be changed within the code first

    Any ideas?
    Attached Files Attached Files
    Last edited by vpan; 06-17-2016 at 01:29 PM.

  2. #2
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    365 ProPlus
    Posts
    15,601

    Re: Need help with code in If statement for pasting entries into another sheet

    Your post does not comply with Rule 3 of our Forum RULES. Use code tags around code.

    Posting code between [CODE]Please [url=https://www.excelforum.com/login.php]Login or Register [/url] to view this content.[/CODE] tags makes your code much easier to read and copy for testing, it also maintains VBA formatting.

    Highlight your code and click the # icon at the top of your post window. More information about these and other tags can be found here



    (This thread should receive no further responses until this moderation request is fulfilled, as per Forum Rule 7)

  3. #3
    Registered User
    Join Date
    06-13-2016
    Location
    NJ
    MS-Off Ver
    2010
    Posts
    95

    Re: Need help with code in If statement for pasting entries into another sheet

    okay, sorry about that, it is changed now

  4. #4
    Registered User
    Join Date
    06-13-2016
    Location
    NJ
    MS-Off Ver
    2010
    Posts
    95

    Re: Need help with code in If statement for pasting entries into another sheet

    Just checking back in during lunch time, anyone have any idea?

    I feel like it should be a simple addition to the IF statement already in there, but Im not familiar with how vba statements are written so I dont know how the syntax would be for it

+ 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. Vb code to hide/unhide rows based on entries on another sheet
    By tcrjmom in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-24-2015, 01:15 PM
  2. IF statement for count of entries outside of specified time
    By jdstuffel in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 06-03-2014, 11:15 AM
  3. IF statement to select 'turn of month' data entries
    By needhalp in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 03-14-2014, 04:41 PM
  4. [SOLVED] Userform code and add and remove entries on sheet
    By Nitefox in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 03-08-2014, 05:12 PM
  5. troubleshoot pasting values in VBA Code from one sheet to another
    By MVscarlet in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 05-12-2010, 06:25 PM
  6. sort out specific entries from Bank statement
    By top1 in forum Excel General
    Replies: 6
    Last Post: 04-16-2010, 08:53 PM
  7. [SOLVED] Why can't I use SUM when pasting HTML code into new sheet.
    By Crosscatch in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 01-09-2006, 12:35 PM

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