+ Reply to Thread
Results 1 to 9 of 9

Pre-Selected Cell

  1. #1
    Registered User
    Join Date
    12-17-2012
    Location
    where i am
    MS-Off Ver
    Excel 2007
    Posts
    11

    Pre-Selected Cell

    Hi
    I have a macro working almost correctly. It copies (as copy as values only) a specific absolute cell reference to another cell. By use of a keyboard shortcut, I did this to save time having to select the first cell to copy. What I want to be able to do is to select a cell just with the mouse then run the macro and it would copy to the selected cell. That is I can paste the value to a cell of my choice, a different cell every time.
    Thanks
    Cnocs

  2. #2
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Pre-Selected Cell

    what is the macro code?
    Josie

    if at first you don't succeed try doing it the way your wife told you to

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

    Re: Pre-Selected Cell

    Hi

    Look at using a doubleclick event to start your macro.

    Because it is worksheet code, it is very easy to install and automatic to use:

    1. right-click the tab name near the bottom of the Excel window
    2. select View Code - this brings up a VBE window
    3. Select worksheet on the left tab
    4. Select doubleclick on the right tab

    paste the stuff in and close the VBE window

    Enjoy

  4. #4
    Registered User
    Join Date
    12-17-2012
    Location
    where i am
    MS-Off Ver
    Excel 2007
    Posts
    11

    Re: Pre-Selected Cell

    Sorry I'm lost, what am I pasting?

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

    Re: Pre-Selected Cell

    Sorry

    Your own code that you say is almost working

  6. #6
    Registered User
    Join Date
    12-17-2012
    Location
    where i am
    MS-Off Ver
    Excel 2007
    Posts
    11

    Re: Pre-Selected Cell

    Please Login or Register  to view this content.
    That's almost right except this bit
    Range("C12").Select
    that bit I want to be the cell I click with the mouse before I run the macro, then it will paste into the chosen cell
    Many thanks
    Cnocs
    Last edited by JosephP; 03-28-2013 at 08:59 AM.

  7. #7
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Pre-Selected Cell

    perhaps just
    Please Login or Register  to view this content.

  8. #8
    Registered User
    Join Date
    12-17-2012
    Location
    where i am
    MS-Off Ver
    Excel 2007
    Posts
    11

    Re: Pre-Selected Cell

    Thankyou!!
    That works perfectly
    thanks
    Sam

  9. #9
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Pre-Selected Cell

    you're welcome :-)

    please don't forget to mark the thread solved (click the 'thread tools' link at the top, then 'mark solved')

+ 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