Results 1 to 5 of 5

The values of a command button determined by other userforms values

Threaded View

  1. #1
    Registered User
    Join Date
    07-28-2013
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    13

    The values of a command button determined by other userforms values

    Hello all!

    So, I have a workbook that has the following items:

    A command button to open a userform with multiple checkbox items to select. The selections are assigned a numerical value and are then summed to display a specific message in a cell.

    A command button to open another userform with two comboboxes in which the selected values (one one selection is permitted per combobox) are then displayed in a specific cell seperated by comma

    A final command button to make a specific calculation based on the values listed in the cells from the above command boxes

    What I cant seem to do is get the final command button to display the calculation:

    Private Sub CalculateButton_Click()
    
    If "recommendation" = "go for it" And "itemmsgbox" = "United States,youth ball team" Then
    Worksheets(1).Range("Calculation").Value = "$197-$250"
    End If
    If "recommendation" = "larger need" And "itemmesgbox" = "United States,teen ball team" Then
    Worksheets(1).Range("Calculation").Value = "$250-$342"
    End If
    
    and so on and so on for a few hundred more variables.
    End Sub
    When I hit the calculate button nothing displays in the box. Am I missing an execution?
    Last edited by Leith Ross; 07-28-2013 at 03:49 PM. Reason: Added Cide Tags

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] how to add the userforms to combobox and open it when pressing the command button ?
    By Shacker in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-12-2013, 09:10 AM
  2. Add a clear values code to command button
    By titantough in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-14-2011, 01:15 AM
  3. Command Button To Reset Values
    By Strugggler in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 02-18-2009, 10:54 PM
  4. [SOLVED] Command Button for PasteSpecial - Values - Transpose
    By Alisha in forum Excel General
    Replies: 0
    Last Post: 03-10-2006, 05:45 PM
  5. [SOLVED] How can I add values in 2 cells using a command button
    By Dr.H.Subramanian in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-17-2005, 03:05 AM

Tags for this Thread

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