IF with a LEFT search

pook_666

Board Regular
Joined
Aug 16, 2018
Messages
94
Hello magicians!

I need help with something probably really basic that I can't get my head around.

I need a formula that searches for the first two numbers in a cell, and if it matches to another, produce a multiplication formula.

For example of what I am trying to get, I have the below where I want a formula in column C where if any of the cells in column A begin with "25", I want to multiply column B by cell F1. If column A doesn't begin with "25" I want to just leave it with what is in column B....so I want to go from this:

1606273533455.png


To this:

1606273612962.png


Believe there is some form of IF, LEFT, FIND formula I can use, but just can't figure it out?

Thanks for the help!
 

Excel Facts

How can you automate Excel?
Press Alt+F11 from Windows Excel to open the Visual Basic for Applications (VBA) editor.
Excel Formula:
=IF(LEFT(A2,2)="25",B2*$F$1,B2)

Paste into C2 and pull down.
 
Last edited by a moderator:
Upvote 0
Solution
Perfect - thank you!
Hi @pook_666. Glad to hear that you received an answer which solved your question quickly!

While you are still around, would you consider clicking on the little checkmark right next to the answer post that @Silverhome provided above, so everybody else knows that this question has a solution?
In fact, it would be also great if you could visit the following link to see your old questions, and also mark the solutions for the ones you also had an answer like this one.

Thank you for the feedback!
 
Upvote 0

Forum statistics

Threads
1,215,576
Messages
6,125,633
Members
449,242
Latest member
Mari_mariou

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