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: 66
Default Determine if specific text is in a cell

I have a worksheet that I would like to add a macro too.
I would like to look at cell, lets say "P2" and check to see if "Grade A"
is in the text. if true then enter the value "Yes" in cell Z2. I will then
copy/paste this lookup down in the z column. I know how to do the final piece
but not sure how to check a cell if certain text is within text of the cell.
This is what I have ,know this probably is incorrect.

With
Range=IF("P2"="*Grade A*" Then
Range Z2="Yes"
Else Not
Range Z2=""
End With

 
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
How to determine the value within specific cell position? Eric Excel Discussion (Misc queries) 5 April 9th 10 01:15 PM
Determine the colour of text in each cell in a range of cells Khurram Excel Programming 7 February 5th 07 02:46 PM
How to determine whether text in cell needs to be wrapped? Joe HM Excel Programming 3 May 25th 06 08:27 PM
Determine number of lines of text within a cell Andibevan[_4_] Excel Programming 2 August 26th 05 03:09 PM
Determine shape name associated with a specific cell [email protected] Excel Discussion (Misc queries) 1 May 12th 05 12:49 AM


All times are GMT +1. The time now is 04:28 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"