LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 116
Default Problem with action on range change

Greetings:

Im having difficulty getting a program to execute on a cell change (F31).

Cell F31 is actually a 1R x 5C range of cells (F31-J31 merged) with a
validation list. There are three possibilities in the list. The text for
each possibility is long, but for simplicity, assume that I need all five
cells and the values in the list are X, Y and Z. When the user selects a
value from the list in F31, cells F59 and F67 should change.

If the user chooses X in F31, I want F59 to show Yes and F67 to show No.
If the user chooses Y in F31, I want F59 to show No and F67 to show Yes.
If the user chooses Z in F31, I want F59 to show Yes and F67 to show Yes.
If the user deletes the entry in F31, I want both F59 and F67 to go blank.

The first three Ifs above work fine. However, when I delete an entry in
F31, F59 and F67 do not change.

Here is the relevant part of the code:

If Target.Address = "$F$31" Then
If MM.Range("F31") = "X" Then
MM.Cells(59, 6) = "Yes"
MM.Cells(67, 6) = "No"
ElseIf MM.Range("F31") = "Y" Then
MM.Cells(59, 6) = "No"
MM.Cells(67, 6) = "Yes"
ElseIf MM.Range("F31") = "Z" Then
MM.Cells(59, 6) = "Yes"
MM.Cells(67, 6) = "Yes"
Else
MM.Cells(59, 6) = ""
MM.Cells(67, 6) = ""
End If
End If

I notice that it DOES work if I unmerge the cells (and use ONLY F31 for
real), but I really do need the five-cell range.

Any ideas as to how I can get this to work? Help is appreciated.

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Change to a Cell causes action Jordan Excel Programming 3 April 6th 06 05:15 PM
Change in action when converting to *.xla Udo Excel Programming 1 March 10th 06 10:26 AM
Cell change causes action [email protected] Excel Programming 5 March 8th 06 02:22 PM
Evaluate cells for change and then action tim Excel Programming 0 February 18th 05 08:43 AM
Automating a date field to change on certain action TODD Excel Programming 3 November 7th 03 05:04 PM


All times are GMT +1. The time now is 03:21 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright 2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"