+ Reply to Thread
Results 1 to 4 of 4

Using Command button to highlight row based on combo box value

  1. #1
    Registered User
    Join Date
    01-15-2019
    Location
    UK
    MS-Off Ver
    Excel 2016
    Posts
    2

    Using Command button to highlight row based on combo box value

    Hi,

    I've built a front end dashboard for a database, I have code that enables me to show the key details based on the value in a combobox, what I am trying to do is programme a command button to activate the row based on a the combo value. I have got the principle working but it currently highlights the row 10 too low eg using row 1 highlights row 10 and row 2 highlights 11 etc


    Private Sub CommandButton1_Click()

    Dim l As Long

    Sheets("Tracker").Select
    Rows("1")("1" & ComboBox1.ListIndex).Select


    Sheets("Tracker").Select

    Unload Me


    End Sub

    Any Idea where I'm going wrong?

  2. #2
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,084

    Re: Using Command button to highlight row based on combo box value

    Try
    Please Login or Register  to view this content.
    Also please edit your post to include code tags, the # icon in the reply/edit window

  3. #3
    Registered User
    Join Date
    01-15-2019
    Location
    UK
    MS-Off Ver
    Excel 2016
    Posts
    2

    Re: Using Command button to highlight row based on combo box value

    Bingo, Thanks, knew it was simples

  4. #4
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,084

    Re: Using Command button to highlight row based on combo box value

    You're welcome & thanks for the feedback

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Search button using command buttom or combo box
    By mcken04 in forum Excel General
    Replies: 0
    Last Post: 09-20-2014, 04:30 AM
  2. [SOLVED] Please Help With Command Button & Combo Boxes
    By VBTroubles in forum Excel Programming / VBA / Macros
    Replies: 16
    Last Post: 09-19-2013, 10:25 AM
  3. Combo Box + Command button = chart. HELP!!!!!
    By flipmagoo in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 02-19-2013, 07:47 PM
  4. [SOLVED] Can I use a combo box instead of a command button?
    By Cosmina Bereschiu in forum Excel Programming / VBA / Macros
    Replies: 17
    Last Post: 01-18-2013, 02:33 AM
  5. Hide/Unhide Combo box via command button
    By staples in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-20-2009, 06:15 AM
  6. Replies: 1
    Last Post: 04-06-2005, 10:06 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