+ Reply to Thread
Results 1 to 4 of 4

Auto Change sheet value

  1. #1
    Forum Contributor
    Join Date
    12-04-2003
    Location
    Burrton, Kansas USA
    MS-Off Ver
    2003
    Posts
    162

    Auto Change sheet value

    Hi again!
    Apparently selecting a date from a data validation list does not trigger a Private Sub Worksheet_Change(ByVal Target As Excel.Range).

    How can I accomplish this? I would like for the code to run when the user selects the new date from the data validation list.

    I could just put a button for the user to click after changing the date but I wanted to ask anyway.

    Thanks!!

  2. #2
    Dave Peterson
    Guest

    Re: Auto Change sheet value

    This problem was fixed in xl2k (xl97 still suffers from the problem).

    How about putting a button near the cell with data|validation that will invoke
    the macro.

    Or dump the data|validation completely and use either a dropdown from the Forms
    toolbar or a combobox from the Control toolbox toolbar.

    Brian Matlack wrote:
    >
    > Hi again!
    > Apparently selecting a date from a data validation list does not
    > trigger a Private Sub Worksheet_Change(ByVal Target As Excel.Range).
    >
    > How can I accomplish this? I would like for the code to run when the
    > user selects the new date from the data validation list.
    >
    > I could just put a button for the user to click after changing the date
    > but I wanted to ask anyway.
    >
    > Thanks!!
    >
    > --
    > Brian Matlack
    > ------------------------------------------------------------------------
    > Brian Matlack's Profile: http://www.excelforum.com/member.php...fo&userid=3508
    > View this thread: http://www.excelforum.com/showthread...hreadid=567100


    --

    Dave Peterson

  3. #3
    Forum Contributor
    Join Date
    12-04-2003
    Location
    Burrton, Kansas USA
    MS-Off Ver
    2003
    Posts
    162
    Thanks Dave!!
    I have a workbook that I create and keep examples in and this code does not work in it.

    However! When I put the code into my users workbook it works fine.????

    I must have a problem in the Example workbook. There are 30 or 40 code examples in it and maybe one of them sets a criterion that fowls-up this one. I'll keep looking!

    Thanks again for your time and help!!!

  4. #4
    Dave Peterson
    Guest

    Re: Auto Change sheet value

    Are all the workbooks running the same version of excel--if yes, what version?

    And when you're snooping, make sure you look to see that you enableevents after
    you've disabled them.

    Brian Matlack wrote:
    >
    > Thanks Dave!!
    > I have a workbook that I create and keep examples in and this code does
    > not work in it.
    >
    > However! When I put the code into my users workbook it works fine.????
    >
    > I must have a problem in the Example workbook. There are 30 or 40 code
    > examples in it and maybe one of them sets a criterion that fowls-up
    > this one. I'll keep looking!
    >
    > Thanks again for your time and help!!!
    >
    > --
    > Brian Matlack
    > ------------------------------------------------------------------------
    > Brian Matlack's Profile: http://www.excelforum.com/member.php...fo&userid=3508
    > View this thread: http://www.excelforum.com/showthread...hreadid=567100


    --

    Dave Peterson

+ 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