+ Reply to Thread
Results 1 to 7 of 7

Using CTRL+F and CTRL+G with Copy/Paste

  1. #1
    Registered User
    Join Date
    05-06-2015
    Location
    CT
    MS-Off Ver
    2010
    Posts
    4

    Red face Using CTRL+F and CTRL+G with Copy/Paste

    Hello All! I've been spinning my wheels for two days now, so I guess it is time to ask for help. I have a spreadsheet (which changes every day) that has multiple rows and 12 columns. The goal is to figure out the number of unique "User IDs" (column A) and then split the work up between two people with each person getting the same number of users. I did the following in my macro:
    Sorted the "User ID" column
    Inserted a pivot table to figure see number of unique users
    Used =COUNT(A:A)/2 to split that list in half
    Used =ROUND(B2,0) to round up in case it was a half number
    Used =CONCATENATE("A",B5) (I was trying to get a cell reference for the half way point
    Then I did CTRL+G and copied and pasted the information that was output above...
    Where this goes wrong, is in the macro, it uses the original value, for example A89, for each time going forward, instead of referencing that cell for the new go to, since it will change each day.

    That was issue 1. Issue 2. After I go to the cell, I need to copy that User ID, go back to the original spreadsheet, hit CTRL+F and paste that information in there. Again, the macro records the original information. I would like it to complete a true copy/paste function each time since the information will change.

    There are a few more steps, but those are the two I keep getting stuck on.
    I'm sure it's obvious, but I'm fairly new to VBA, but I'm hoping I can get this to work, or maybe something else that will serve the same purpose. Any help is appreciate! Thanks for looking :-)

  2. #2
    Forum Expert
    Join Date
    12-14-2012
    Location
    London England
    MS-Off Ver
    MS 365 Office Suite.
    Posts
    8,448

    Re: Using CTRL+F and CTRL+G with Copy/Paste

    It sounds like you are using a recorded macro.

    You need to modify it a little

    Insert this line:

    Please Login or Register  to view this content.
    This looks for the last populated cell in column 1 so modify it to match you data.

    then do a find replace

    Replace 89" with " & LR

    Your macro should then work better,
    My General Rules if you want my help. Not aimed at any person in particular:

    1. Please Make Requests not demands, none of us get paid here.

    2. Check back on your post regularly. I will not return to a post after 4 days.
    If it is not important to you then it definitely is not important to me.

  3. #3
    Registered User
    Join Date
    05-06-2015
    Location
    CT
    MS-Off Ver
    2010
    Posts
    4

    Re: Using CTRL+F and CTRL+G with Copy/Paste

    Hi mehmetcik!
    Thank you so much for your reply, I really appreciate your assistance. So, here is my recorded macro:
    Please Login or Register  to view this content.

    For the first one, the data I want it to "go to" is being referenced in the last cell in column 2. For the second one, the data I would like it to find is being referenced in the last cell in column 14. I guess I'm just not entirely sure where I should be putting "LR = Cells(rows.count,1).End(xlUp).Row" either. If you have some time, do you think you could provide a little more help please?

    Thanks!
    waves678
    Last edited by waves678; 05-08-2015 at 03:26 PM.

  4. #4
    Forum Expert
    Join Date
    12-14-2012
    Location
    London England
    MS-Off Ver
    MS 365 Office Suite.
    Posts
    8,448

    Re: Using CTRL+F and CTRL+G with Copy/Paste

    Firstly You Really need to use Code Tags.

    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)


    Secondly you should have attached your spreadsheet, so we can step through it and edit it.

    Attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic


    Please Login or Register  to view this content.
    Last edited by mehmetcik; 05-07-2015 at 07:18 PM.

  5. #5
    Registered User
    Join Date
    05-06-2015
    Location
    CT
    MS-Off Ver
    2010
    Posts
    4

    Red face Re: Using CTRL+F and CTRL+G with Copy/Paste

    First off, thank you for your patience and instructions! It is appreciated, I'm very new to VBAs and Macros and am trying to learn more in an effort to implement efficiency improvements to a lot of burdened colleagues. I've attached a small sample, the normal sheets are typically 400 - 2000 rows depending on the time of year. There may be a much simpler way to achieve what I'm looking to do and I just haven't come up with it yet, so I'm open to drastic changes as well as the same goal is accomplished. Thank you again for the help, it is very generous of you!
    waves678
    Attached Files Attached Files

  6. #6
    Forum Expert
    Join Date
    12-14-2012
    Location
    London England
    MS-Off Ver
    MS 365 Office Suite.
    Posts
    8,448

    Re: Using CTRL+F and CTRL+G with Copy/Paste

    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    05-06-2015
    Location
    CT
    MS-Off Ver
    2010
    Posts
    4

    Re: Using CTRL+F and CTRL+G with Copy/Paste

    Thank you, you've been very helpful!

+ 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. [SOLVED] CTRL+C & CTRL+V copy single but pasting tab delimited spaced
    By Jack7774 in forum Excel General
    Replies: 4
    Last Post: 03-20-2015, 08:23 AM
  2. Disable cut,copy,paste(including ctrl x, ctrl c n ctrl v)
    By Ramboexcel in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-16-2014, 01:00 AM
  3. Help needed : Unable to use CTRL+C or CTRL+D to copy formula
    By Elangovan89 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-09-2014, 10:20 AM
  4. [SOLVED] Problem using ctrl+Z on copy-paste-value macro
    By amphinomos in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-24-2014, 09:12 AM
  5. Replies: 0
    Last Post: 09-10-2013, 08:31 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