Adding another condition to VBA code "Case"

Hello everybody,

When I add another condition to the code it gives a fulse result
Case "Buy"

Open in new window

by
Case "Buy", "Achat", "Souscription"

Open in new window

And also
Case "Sell"

Open in new window

by
Case "Sell", "Vente", "Rachat"

Open in new window

it gives a fulse reslut

Thank you for helping me
Adil KhAsked:
Who is Participating?
 
Kyle AbrahamsSenior .Net DeveloperCommented:
Could it be case sensitive?  Make sure you're using option compare text.

https://docs.microsoft.com/en-us/dotnet/visual-basic/language-reference/statements/select-case-statement
0
 
Bill PrewCommented:
Please share the full statement involved, hard to tell from just one piece of a case statement what the problem is...


»bp
0
 
Adil KhAuthor Commented:
The problem was just in the formula I should have add the creteria in the formula Cells "L9" IF(or(E9="Vente";E9="Rachat"...

That was the problem

Thanks for helping
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.