• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

How to create a function button in a cell?

pimpyodapimp

New Member
I'm working on a spread sheet at work and I want to be able set a single cell as a function button. Example like I want to click A1 and it copy everything to my clip board from A2 - A10. Any help would be greatly appreciated
 
Hi, pimpyodapimp!


First of all welcome to Chandoo's website Excel forums. Thank you for your joining us and glad to have you here.


As a starting point I'd recommend you to read the three first green sticky topics at this forums main page. There you'll find general guidelines about how this site and community operates (introducing yourself, posting files, netiquette rules, and so on).


Among them you're prompted to perform searches within this site before posting, because maybe your question had been answered yet.


Feel free to play with different keywords so as to be led thru a wide variety of articles and posts, and if you don't find anything that solves your problem or guides you towards a solution, you'll always be welcome back here. Tell us what you've done, consider uploading a sample file as recommended, and somebody surely will read your post and help you.


And about your question...


You should insert a command button (either form control or ActiveX control, from Programmer tab, Insert), then resize it to fill cell size, and assign proper code.


Regards!
 
Good day pimpyodapimp


If you open the uploaded Excel file you will see a list of prime numbers, clear the clip board and put your cursor in A2 and press CTRL+K (does not have to be upper case) you will see that column in the clip board, while you have the CRTL key depressed keep pressing the K button and it will copy the next column to the clip board when you have all you need select the “Sorted List” column and in the clip board window select “Paste All”.

This is done with a Macro, select Macro from the ribbon to edit a view the small code


https://dl.dropbox.com/u/75495784/Copy_List.xlsm
 
Back
Top