Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Programming / March 2008

Tip: Looking for answers? Try searching our database.

Trapping making a selection from a dropdown validation list

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Pete Rooney - 20 Mar 2008 10:42 GMT
I have produced some event code which altomatically simulates clicking the
drop arrow box and zooms the display for ease of reading whenever a cell
referring to a validation list is selected. I want the zoom to return to its
previous lower setting once a selection has been made from the dropdown list,
but at the moment I have to select another cell in order for this to happen
(see code below).

Is it possible to trap the action of selecting an item from the drop down
list, so I can reset the zoom without having to set another cell first?

Here's the code:

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
   ActiveWindow.Zoom = 70
   If Target.Cells.Count = 1 Then 'Check that the selected cell is a single
cell
       If Not Intersect(Target, Range("ColPhase")) Is Nothing Then
           ActiveWindow.Zoom = 150
           Application.SendKeys ("%{DOWN}")
       End If
   End If
End Sub

Regards & thanks in advance!

Pete
Pete Rooney - 20 Mar 2008 10:53 GMT
I just realised that my question doesn't make any sense...

What I meant was, if I click a cell in "ColPhase", the zoomup takes place
correctly.
When I  make a selection from the dropdown list, the zoomdown takes place
correctly. If, however I want to click the dropdown button again on the SAME
cell, the zoom DOESN'T work (because I haven't changed the selected cell).
What I want to do is trap the event of clicking the dropdown arrow to see if
I can zoomup again without selecting another cell in "ColPhase".

Does this make more sense?

Thanks

Pete

> I have produced some event code which altomatically simulates clicking the
> drop arrow box and zooms the display for ease of reading whenever a cell
[quoted text clipped - 22 lines]
>
> Pete
Dave Peterson - 20 Mar 2008 12:48 GMT
Maybe you could tap into the worksheet_change event.

There is a potential problem if you're running xl97 depending on how the
data|validation was created, though.

> I have produced some event code which altomatically simulates clicking the
> drop arrow box and zooms the display for ease of reading whenever a cell
[quoted text clipped - 22 lines]
>
> Pete

Signature

Dave Peterson

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.