Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Formula help

Posted on 2011-02-25
4
Medium Priority
?
211 Views
Last Modified: 2012-05-11
Hello all, need help modifying this formula below, I need to add if they value returned is #value or an error, then value will be 7.

=TRIM(RIGHT(LEFT(Sheet4!A116,FIND("SM",Sheet4!A116)-1),LOOKUP(10^6,RIGHT(LEFT(Sheet4!A116,FIND("SM",Sheet4!A116)-1),{1,2,3,4,5,6})+0,{1,2,3,4,5,6})))
0
Comment
Question by:sandramac
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 9

Accepted Solution

by:
McOz earned 2000 total points
ID: 34982337
try:
=IFERROR(TRIM(RIGHT(LEFT(Sheet4!A116,FIND("SM",Sheet4!A116)-1),LOOKUP(10^6,RIGHT(LEFT(Sheet4!A116,FIND("SM",Sheet4!A116)-1),{1,2,3,4,5,6})+0,{1,2,3,4,5,6}))),7)

Open in new window

0
 
LVL 50

Expert Comment

by:barry houdini
ID: 34982355
Is it OK if it's a text value (the 7)? If so try

=LOOKUP("zzz",IF({1,0},"7",TRIM(RIGHT(LEFT(Sheet4!A116,FIND("SM",Sheet4!A116)-1),LOOKUP(10^6,RIGHT(LEFT(Sheet4!A116,FIND("SM",Sheet4!A116)-1),{1,2,3,4,5,6})+0,{1,2,3,4,5,6})))))

regards, barry
0
 
LVL 50

Expert Comment

by:barry houdini
ID: 34982369
My solution assumes you have Excel 2003 or earlier - if you are using Excel 200 go with cOz's suggestion......

regards, barry
0
 
LVL 50

Expert Comment

by:barry houdini
ID: 34982380
Sorry garbled my reply above - I meant "If you are using Excel 2007 or later go with McOz's suggestion"

barry
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A little background as to how I came to I design this code: Around 5 years ago I designed an add-in that formatted Excel files to a corporate standard, applying different cell colours and font type depending on whether the cells contained inputs,…
You need to know the location of the Office templates folder, so that when you create new templates, they are saved to that location, and thus are available for selection when creating new documents.  The steps to find the Templates folder path are …
The viewer will learn how to create two correlated normally distributed random variables in Excel, use a normal distribution to simulate the return on different levels of investment in each of the two funds over a period of ten years, and, create a …
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

721 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question