Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 195
Default Find troubles

I want to select a student name from AE3 Data Validation dropdown and class
from AF3 Data Validation dropdown and wind up activating the class under
the student name.

This finds the student name, but stops the
Sub FindClass()
Dim ThisClass, FoundClass As Range
Columns("A:A").Find(Range("AE3")).Activate
ThisClass = Range("AF3").Value
Set FoundClass = Selection.Find(What:=ThisClass, _
After:=ActiveCell, LookIn:=xlValues, _
LookAt:=xlPart, SearchOrder:=xlByRows, _
SearchDirection:=xlNext, MatchCase:=False)
End Sub

--
David
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 195
Default Find troubles

David wrote

I want to select a student name from AE3 Data Validation dropdown and
class from AF3 Data Validation dropdown and wind up activating the
class under the student name.

This finds the student name, but stops the
Sub FindClass()
Dim ThisClass, FoundClass As Range
Columns("A:A").Find(Range("AE3")).Activate
ThisClass = Range("AF3").Value
Set FoundClass = Selection.Find(What:=ThisClass, _
After:=ActiveCell, LookIn:=xlValues, _
LookAt:=xlPart, SearchOrder:=xlByRows, _
SearchDirection:=xlNext, MatchCase:=False)
End Sub


Fumbled around and came up with this:
Sub FindClass()
Dim ThisClass As String, Rng As Range
Columns("A:A").Find(Range("AE3")).Activate
ThisClass = Range("AF3").Value
Set Rng = Range(ActiveCell.Address, Range(ActiveCell.Address).End(xlDown))
Rng.Find(ThisClass).Select
End Sub

Works, anyway.

--
David
Reply
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
Troubles Jonas Krogh Excel Discussion (Misc queries) 1 October 22nd 09 11:14 AM
COM Add-in Troubles Howard Excel Discussion (Misc queries) 0 May 22nd 07 01:59 PM
IF troubles JG Excel Worksheet Functions 6 December 24th 06 04:58 AM
List Box Troubles LostNFound Excel Discussion (Misc queries) 1 January 20th 06 06:46 PM
Lookup Troubles Again H Excel Worksheet Functions 1 April 18th 05 05:06 PM


All times are GMT +1. The time now is 02:23 PM.

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

About Us

"It's about Microsoft Excel"