+ Reply to Thread
Results 1 to 7 of 7

Two Drop Down Boxes Always the Same, Linked

  1. #1
    Registered User
    Join Date
    10-08-2008
    Location
    Indy
    Posts
    14

    Two Drop Down Boxes Always the Same, Linked

    Good afternoon,

    I have searched around and have not found the exact solution to my problem. I have two drop down boxes, within the same workbook, on different sheets.

    Is there a way to link them together so they are always equal to each other? I want to be able to select a value from the 1st drop down box, and have the 2nd drop down box automatically change to the same field. I also would like to be able to select a value from the 2nd box, and have the 1st box automatically update with that value.

    I am aware that I could make the 2nd box equal the 1st one by referencing the 1st box's cell, but don't know how to make it work both ways.

    Thanks in advance!

    Edit: I did not mean to post this in the New User's forum; it was meant for the General forum.
    Last edited by gema; 10-13-2009 at 02:57 PM.

  2. #2
    Forum Contributor GuruWannaB's Avatar
    Join Date
    01-24-2008
    Location
    An hour due East of Cowtown Ohio
    MS-Off Ver
    2010
    Posts
    421

    Re: Two Drop Down Boxes Always the Same, Linked

    Right click on the first dropdown box while in design mode and view the format control - select a cell in the Cell Link field. Now right click on the second box and select the same cell for the cell link. That should do it
    Last edited by GuruWannaB; 10-13-2009 at 03:55 PM.
    I help because of the Pavlovian dog that resides in the inner me...so if you are happy with the results, please add to my reputation. It helps keep me motivated!



    Please mark your threads as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Forum Expert Whizbang's Avatar
    Join Date
    08-05-2009
    Location
    Greenville, NH
    MS-Off Ver
    2010
    Posts
    1,395

    Re: Two Drop Down Boxes Always the Same, Linked

    I don't know what GuruWannaB means, but here is a solution I worked out.

    Enter the following macro into your sheet:

    Please Login or Register  to view this content.
    See the attached.
    Attached Files Attached Files
    Last edited by Whizbang; 10-13-2009 at 03:54 PM.

  4. #4
    Registered User
    Join Date
    10-08-2008
    Location
    Indy
    Posts
    14

    Re: Two Drop Down Boxes Always the Same, Linked

    Quote Originally Posted by GuruWannaB View Post
    Right click on the first dropdown box while in design mode and view the format control - select a cell in the Cell Link field. Now right click on the second box and select the same cell for the cell link. That should do it
    That may be a possible solution for me. I only see the format control selection when I am using a combo box form. I created my drop down box by clicking Data->Data Validation, then allow list. It appears it works differently than the form. I may modify my drop down boxes to be forms instead.

    Quote Originally Posted by Whizbang View Post
    I don't know what GuruWannaB means, but here is a solution I worked out.

    Enter the following macro into your sheet:

    Please Login or Register  to view this content.
    See the attached.
    That worked, but then it kept throwing an error and wanting me to debug. It then proceeded to crash Excel. I'll play with it some more and see if I can figure anything out.

    I attached a simplified version of what I'm working with.
    Attached Files Attached Files

  5. #5
    Forum Expert Whizbang's Avatar
    Join Date
    08-05-2009
    Location
    Greenville, NH
    MS-Off Ver
    2010
    Posts
    1,395

    Re: Two Drop Down Boxes Always the Same, Linked

    Are you in Worksheet_Change or Worksheet_SelectionChange?

    Edit**

    See the attached
    Attached Files Attached Files
    Last edited by Whizbang; 10-13-2009 at 04:27 PM.

  6. #6
    Registered User
    Join Date
    10-08-2008
    Location
    Indy
    Posts
    14

    Re: Two Drop Down Boxes Always the Same, Linked

    Quote Originally Posted by Whizbang View Post
    Are you in Worksheet_Change or Worksheet_SelectionChange?

    Edit**

    See the attached
    Sorry for the delay in response, this is one of many projects I am currently working on.

    I do not know what you mean by your question? I am very familiar with Excel, just not with VBA. I can record macros, but that's about it.

    I open the file you attached, enable macros, and when I change one of the values in the drop down. It then pops up and says:

    "Run-time error '-2147417848 (80010108)':

    Method of 'Value' of object 'Range' failed"

    Any idea what I'm doing wrong?

  7. #7
    Forum Expert Whizbang's Avatar
    Join Date
    08-05-2009
    Location
    Greenville, NH
    MS-Off Ver
    2010
    Posts
    1,395

    Re: Two Drop Down Boxes Always the Same, Linked

    *Shrugs* It looks like you are using a different version of Excel. I am using Excel 2003. Maybe it's that. The file works just fine for me.

+ 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