+ Reply to Thread
Results 1 to 5 of 5

Custom Button Creation

  1. #1
    Registered User
    Join Date
    11-13-2009
    Location
    California
    MS-Off Ver
    Excel 2003
    Posts
    5

    Question Custom Button Creation

    Hi, I have a simple function to perform, but lack the know-how. Here's what I need...

    I have an individual cell that contains a numerical value that remains constant - lets say it's 40. I would like to just select that cell (is there a way to make it a button of some sorts) and then have it's value automatically added (yes just added) to another numerical value in a different cell (this cell will be a value of, lets say 70, and that would be a value that I enter and can change at will). I would like the sum of those to be shown in different cell.

    Thats all - I just don't know how to do it - excel noob. Yes, I know how to add those numbers in my head and enter it in the cell I want, but this will get more complex and expanded, I just need a basic start. Thanks!

    Thank you,
    Justin
    Last edited by toothbrush; 11-13-2009 at 03:00 PM.

  2. #2
    Forum Expert Palmetto's Avatar
    Join Date
    04-04-2007
    Location
    South Eastern, USA
    MS-Off Ver
    XP, 2007, 2010
    Posts
    3,978

    Re: Custom Button Creation

    This doesn't require VBA programming, which is forum you posted in.

    for discussion:

    Cell A1 = 40
    Cell B1 = 70
    Cell C1 formula: =A1+B1 or =SUM(A1:B1)

    The value of cell C1 will update per whatever changes in values are made in A1 or B1.

    Did I misss the point here or was your task just this simple?
    Palmetto

    Do you know . . . ?

    You can leave feedback and add to the reputation of all who contributed a helpful response to your solution by clicking the star icon located at the left in one of their post in this thread.

  3. #3
    Registered User
    Join Date
    11-13-2009
    Location
    California
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: Custom Button Creation

    Yes it's that simple but what I would like to do is turn (in your example) cell A1 into a "button" which when pressed will generate the sum calculation in cell C1.

    The reason for this is because I'd like to add additional selectable "buttons". For instance, if we add another cell to this, A2, and it's value is 50. When I press our "button" (which is a separate button from cell A1) I would like the value in cell C1 to change.

    So...

    Cell A1 = 40 (this cell I'd like to be a "button", or "selection" and this value will not change)
    Cell A2 = 50 (similar to cell A1)

    Cell B1 = 70 (this will be any numerical value I'd like, no special function here)

    Cell C1 = A1+B1 (when "button" A1 is pressed), or A2+B1 (when "button" A2 is pressed)

    Thank you for your help, I see that I didn't explain my original functions very well.

    Best,
    Justin
    Last edited by toothbrush; 11-13-2009 at 04:25 PM.

  4. #4
    Forum Expert Palmetto's Avatar
    Join Date
    04-04-2007
    Location
    South Eastern, USA
    MS-Off Ver
    XP, 2007, 2010
    Posts
    3,978

    Re: Custom Button Creation

    I fail to see what you are trying to accomplish with this approach, but here is the basic code. I assumed you want to clear cell C1 each time you click the button - advise if this is not the case.

    You will need to create two buttons from the Forms Tool Box and assign the code to the respective button. The code needs to copied and pasted into a standard VBA module.

    Please Login or Register  to view this content.
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    11-13-2009
    Location
    California
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: Custom Button Creation

    Thats it - Thanks!

+ 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