i used google sheet : i need function in c2

dabielcrbyton

New Member
Joined
May 28, 2017
Messages
39
i used google sheet :

a1bcd
a22S 5D [AC KH 2S QS JS]
a3
a4


please i have this string in b2
2S 5D [AC KH 2S QS JS]
i need function in c2
to do that :
we can see that before the [ ]
are the sign "2"
i need function that determinant if inside the [ ]
their are also the sign 2
and if so i need it to writing in c2
the sign 2

the same thing i need to do with the sign:
A
K
q
J
10
9
8
7
6
5
4
3


and if the function don't find :
i want it to write "no" in c2
 

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.
Is this what you want to do?
Book1
BCD
22S 5D [AC KH 2S QS JS]2Sno
Sheet1
Cell Formulas
RangeFormula
C2C2=IF(ISNUMBER(SEARCH(LEFT(B2,2),RIGHT(B2,16))),LEFT(B2,2),"no")
D2D2=IF(ISNUMBER(SEARCH(MID(B2,4,2),RIGHT(B2,16))),LEFT(B2,2),"no")
 
Upvote 0
Is this what you want to do?
Book1
BCD
22S 5D [AC KH 2S QS JS]2Sno
Sheet1
Cell Formulas
RangeFormula
C2C2=IF(ISNUMBER(SEARCH(LEFT(B2,2),RIGHT(B2,16))),LEFT(B2,2),"no")
D2D2=IF(ISNUMBER(SEARCH(MID(B2,4,2),RIGHT(B2,16))),LEFT(B2,2),"no")

thank you very much



but i have a problem
your function give me result of "no" to this
2S KC [AC KH QS 3H JS]

but as you see there is
K before the [ ]
and K inside the [ ]
so the result sould say K




also there is a problem with this :
2S 7C [2C 7H 4C 3H JS]
because there is also 2 and 7 before the [ ]
and 2 and 7 inside the [ ]
so the result should say 2 7
 
Upvote 0
I had set the formula to match the face value and suit of the card. These versions will do face value only.

Excel Formula:
=IF(ISNUMBER(SEARCH(MID(B2,2,1),RIGHT(B2,16))),LEFT(B2,2),"no")
Excel Formula:
=IF(ISNUMBER(SEARCH(MID(B2,5,1),RIGHT(B2,16))),LEFT(B2,2),"no")
 
Upvote 0
thank you very much



but i have a problem
your function give me result of "no" to this
2S KC [AC KH QS 3H JS]

but as you see there is
K before the [ ]
and K inside the [ ]
so the result sould say K




also there is a problem with this :
2S 7C [2C 7H 4C 3H JS]
because there is also 2 and 7 before the [ ]
and 2 and 7 inside the [ ]
so the result should say 2 7

I had set the formula to match the face value and suit of the card. These versions will do face value only.

Excel Formula:
=IF(ISNUMBER(SEARCH(MID(B2,2,1),RIGHT(B2,16))),LEFT(B2,2),"no")
Excel Formula:
=IF(ISNUMBER(SEARCH(MID(B2,5,1),RIGHT(B2,16))),LEFT(B2,2),"no")
yes i need the face value
and not the suit

but i need also the the
J q K A
because this is poker cards


i will publish it again in the:
General Discussion & Other Applications
thank you my friend
 
Upvote 0
I just realised my error.
Excel Formula:
=IF(ISNUMBER(SEARCH(LEFT(B2,1),RIGHT(B2,16))),LEFT(B2,2),"no")
Excel Formula:
=IF(ISNUMBER(SEARCH(MID(B2,4,1),RIGHT(B2,16))),MID(B2,4,2),"no")
 
Upvote 0
a1bcd
a29 K [9 K J 3 J]9 [



that what it show in c2
9

it should show
9 k


because 9 and k
show before the [ ]
and also inside the [ ]



as i say my friend
i using google sheet
 
Upvote 0

Forum statistics

Threads
1,223,391
Messages
6,171,822
Members
452,426
Latest member
cmachael

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top