+ Reply to Thread
Results 1 to 5 of 5

Command Button Output text

  1. #1
    Forum Contributor
    Join Date
    04-03-2009
    Location
    USA, California
    MS-Off Ver
    Excel 2007
    Posts
    385

    Command Button Output text

    Hi everyone I need help coding a command button to output text based on the contents of combobox1 and combobox2. The text should be placed in the next available cell starting in cell b3 for combobox1 and starting in cell c3 for combobox2. Each time submit is clicked the name and number associated with that name should go in the next free cell in the spreadsheet.

    So for example the user choses name1 and number6 cell b3 would read name1 and cell c3 would read number6 after submit is clicked. The user then choses name58 and number12 and presses submit again cell b4 would read name58 and cell c4 would read number12.

    Anyhelp with this?
    Last edited by randell.graybill; 06-02-2009 at 10:13 PM.

  2. #2
    Forum Expert Simon Lloyd's Avatar
    Join Date
    03-02-2004
    Location
    locked in the cage
    MS-Off Ver
    All the ones my homepage shows
    Posts
    3,161

    Re: Command Button Output text

    use this in your command button click event, i'm assuming you have data in column b to rows 3 and the same with C
    Please Login or Register  to view this content.
    Not all forums are the same - seek and you shall find

  3. #3
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Command Button Output text

    Where are the comboboxes & button - on the sheet or a userform?
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  4. #4
    Forum Contributor
    Join Date
    04-03-2009
    Location
    USA, California
    MS-Off Ver
    Excel 2007
    Posts
    385

    Re: Command Button Output text

    They are on a userform, but I would like to move everything to sheet level instead of userform.

    The above code did work however.

  5. #5
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Command Button Output text

    The code should will with controls on the sheet.

+ 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