Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a spreadsheet that users may update. When they do update a value, I
want to check that it falls within certain ranges dependant on other cells in the sheet (so I can't use the data validation function). I am using worksheet_change which works OK in terms of detecting a change, but how can I find out which cell they have changed. I tried using activecell, but that does not work if they move to another cell using the mouse, rather than pressing return. Any Ideas Thanks |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Create duplicate cells that you want to refer to on your input worksheet. Let's say your input worksheet is Sheet1 and ranges you want to validate the input against in Sheet 2 and 3. Sheet1!A1=Sheet2!B10 Sheet1!A2=Sheet3!C45 Now you can use data validation by using values on A1 and A2 on Sheet1. -- renegan ------------------------------------------------------------------------ renegan's Profile: http://www.excelforum.com/member.php...o&userid=10450 View this thread: http://www.excelforum.com/showthread...hreadid=528159 |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
The argument of the change function is Target as Range and that is the cell
that was just changed... Add this code to your change event to see what I mean msgbox "Cell " & target.address & " was changed to " & target.value -- HTH... Jim Thomlinson "HRman" wrote: I have a spreadsheet that users may update. When they do update a value, I want to check that it falls within certain ranges dependant on other cells in the sheet (so I can't use the data validation function). I am using worksheet_change which works OK in terms of detecting a change, but how can I find out which cell they have changed. I tried using activecell, but that does not work if they move to another cell using the mouse, rather than pressing return. Any Ideas Thanks |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Worksheet_Change procedure question | Excel Programming | |||
Worksheet_Change procedure question | Excel Programming | |||
Excel VBA .... Worksheet_Change(ByVal Target As Range) question | Excel Programming | |||
Noob question - Worksheet_Change | Excel Programming | |||
Worksheet_Change event question | Excel Programming |