eddymoney88
New Member
- Joined
- Jul 20, 2016
- Messages
- 5
I have an worksheet where I need to find all the weights (in kilograms and grams), but I only want to find the numbers (as I will easily be able to tell if they're KG or G just by the value it returns). If it's kilos, then the value I'm looking for could have 1 or 2 digits, and if it's in grams then it will always be 3 digits.
I've used: =IFERROR(MID(F2,SEARCH("kg",F2)-2,2),MID(F2,SEARCH("G",F2)-3,3)) but it returns a specific number of characters, whereas I want to just isolate the numbers.
Here's an example
<tbody>
</tbody>
I've used: =IFERROR(MID(F2,SEARCH("kg",F2)-2,2),MID(F2,SEARCH("G",F2)-3,3)) but it returns a specific number of characters, whereas I want to just isolate the numbers.
Here's an example
PureDogFood3KG | 3 |
CatFood500GBag | 500 |
PuppyFood15KG | 15 |
<tbody>
</tbody>