Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
What is the proper application of a wild card in an "if
then" statement. I am trying to select by the first three letters of a field. using the asterik after the three letters does not work all my resources do not show any examples. Any ideas?? thanks |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
As always, it is best to post your code for comments.
-- Don Guillett SalesAid Software "jstocka" wrote in message ... What is the proper application of a wild card in an "if then" statement. I am trying to select by the first three letters of a field. using the asterik after the three letters does not work all my resources do not show any examples. Any ideas?? thanks |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi
try something like If lcase(left(activecell.value,3))="abc" then msgbox "starts with 'abc'" end if -- Regards Frank Kabel Frankfurt, Germany "jstocka" schrieb im Newsbeitrag ... What is the proper application of a wild card in an "if then" statement. I am trying to select by the first three letters of a field. using the asterik after the three letters does not work all my resources do not show any examples. Any ideas?? thanks |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
One way:
=IF(LEFT(Q11,3)="abc","good","bad") Regards Trevor "jstocka" wrote in message ... What is the proper application of a wild card in an "if then" statement. I am trying to select by the first three letters of a field. using the asterik after the three letters does not work all my resources do not show any examples. Any ideas?? thanks |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Not sure what you are looking for. Is this what you mean by a "wild card?"
Sub Demo() If ActiveCell Like "[A-Z,a-z][A-Z,a-z][A-z,a-z]*" Then MsgBox "Starts w/ 3 Letters" End If End Sub -- Dana DeLouis Using Windows XP & Office XP = = = = = = = = = = = = = = = = = "jstocka" wrote in message ... What is the proper application of a wild card in an "if then" statement. I am trying to select by the first three letters of a field. using the asterik after the three letters does not work all my resources do not show any examples. Any ideas?? thanks |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
"jstocka" wrote in message ...
What is the proper application of a wild card in an "if then" statement. I am trying to select by the first three letters of a field. using the asterik after the three letters does not work all my resources do not show any examples. Any ideas?? thanks This may not be what you need but you can grab the first three letters of a cell w/ =Left(A1,3) This will give you the first 3 letters of whatever is in cell A1 & then you can go from there. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Wild Card Search | Excel Worksheet Functions | |||
Wild card * in Array | Excel Worksheet Functions | |||
Wild Card Vlookups | Excel Discussion (Misc queries) | |||
Wild Card Search | Excel Worksheet Functions | |||
Wild card * | Excel Worksheet Functions |