+ Reply to Thread
Results 1 to 9 of 9

Making a combobox visible or invisible

  1. #1
    Registered User
    Join Date
    12-03-2018
    Location
    Brussels
    MS-Off Ver
    2010
    Posts
    3

    Making a combobox visible or invisible

    Hello,

    I have a combobox on my sheet. I want to make it disappear when a value in a certain cell is <>1.

    This is the code I have set:

    Please Login or Register  to view this content.
    No the problem is, that my combo box stays visible, also when the value is other then 1. (I have runned it step by step, and when it goes the the else, it says combobox.visible = true while I have written = false (see attachment).

    Can anybody please help me?

    Thank you!
    Attached Images Attached Images
    Last edited by jeffreybrown; 12-03-2018 at 10:22 AM. Reason: Please use code tags!

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Making a combobox visible or invisible

    If you want it invisible when the user form is opened then use the Initialise event of the UserForm and set the property of the Comobox to false if the cell is <>1
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,316

    Re: Making a combobox visible or invisible

    I have a combobox on my sheet. I want to make it disappear when a value in a certain cell is <>1.
    If I understand what you are trying to achieve, if the combobox is on your sheet, then you need a sheet event.

    Please Login or Register  to view this content.
    HTH
    Regards, Jeff

  4. #4
    Registered User
    Join Date
    12-03-2018
    Location
    Brussels
    MS-Off Ver
    2010
    Posts
    3

    Re: Making a combobox visible or invisible

    Hello,

    I'm sorry but I don't understand. (I'm just an amateur :-) )

    I have uploaded my excel file. In fact, I want that the combobox situated in cel G6 appears when C6= Dealer and E6 = yes.
    All other options, the combobox has to disappear.

    Can anyone help me please?

    Thank you!
    Attached Files Attached Files

  5. #5
    Forum Expert rorya's Avatar
    Join Date
    08-13-2008
    Location
    East Sussex, UK
    MS-Off Ver
    365 Ent SAC
    Posts
    8,885
    Rory

  6. #6
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,474

    Re: Making a combobox visible or invisible

    Combobox_visible() is not a worksheet_event

    Possibly use the worksheet_change event

    Please Login or Register  to view this content.

  7. #7
    Forum Expert CK76's Avatar
    Join Date
    06-16-2015
    Location
    ONT, Canada
    MS-Off Ver
    Office 365 ProPlus
    Posts
    5,855

    Re: Making a combobox visible or invisible

    Something like below?
    Please Login or Register  to view this content.
    ?Progress isn't made by early risers. It's made by lazy men trying to find easier ways to do something.?
    ― Robert A. Heinlein

  8. #8
    Registered User
    Join Date
    12-03-2018
    Location
    Brussels
    MS-Off Ver
    2010
    Posts
    3

    Re: Making a combobox visible or invisible

    Super!!! It works! Thank you so much! :-)

  9. #9
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,316

    Re: Making a combobox visible or invisible

    Your post does not comply with Rule 3 of our Forum RULES. Do not crosspost your question on multiple forums without including links here to the other threads on other forums.

    Cross-posting is when you post the same question in other forums on the web. The last thing you want to do is waste people's time working on an issue you have already resolved elsewhere. We prefer that you not cross-post at all, but if you do (and it's unlikely to go unnoticed), you MUST provide a link (copy the url from the address bar in your browser) to the cross-post.

    Expect cross-posted questions without a link to be closed and a message will be posted by the moderator explaining why. We are here to help so help us to help you!

    Read this to understand why we ask you to do this, and then please edit your first post to include links to any and all cross-posts in any other forums (not just this site).

    Please make sure to include the full link, so that other members will be permitted to continue helping you

    Note that if you have fewer than 10 posts, you may need to type the link, or past it in pieces (or ask a mod to do that for you)

+ 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. making optionbutton visible or invisible by loop
    By lettersofberk in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-13-2013, 12:33 PM
  2. Making sheets visible/invisible with password
    By manali7120 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-25-2013, 10:32 AM
  3. Making a command button Visible/Invisible based on a cell Colour
    By AmberLou in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-15-2012, 05:38 AM
  4. How can i make visible or invisible groupobjects using a combobox
    By drodriguez93 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-16-2012, 02:22 AM
  5. Making info visible or invisible depending on outcome of event
    By frogboy in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-09-2012, 06:32 AM
  6. Making part of a grouped object visible / invisible
    By Notgoodinexcel in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-17-2011, 05:22 AM
  7. Making an image visible/ invisible as cell selection changes
    By deadlyduck in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-08-2011, 07:47 AM
  8. Row Visible / Invisible
    By RoyMakaay1985 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-03-2009, 06:00 AM

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