ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   New Users to Excel (https://www.excelbanter.com/new-users-excel/)
-   -   Show a blank result in a cell when there is no value in the "Lookup" cell (https://www.excelbanter.com/new-users-excel/153067-show-blank-result-cell-when-there-no-value-lookup-cell.html)

Michael Slater

Show a blank result in a cell when there is no value in the "Lookup" cell
 
I apologize if this question has been asked, but I have been unable to find
an answer searching the topics.

I'm using the following formula in cell C3:

=INDEX(LastName,MATCH(A3,EmpID,0))

When I type in an employee ID in A3, his/her last name shows in C3.
However, when there is no value in A3, C3 shows error "#N/A".

Is there a way to show a blank cell in C3 until a value is entered into A3?

Thanks in advance!

Mike


joeu2004

Show a blank result in a cell when there is no value in the "Lookup" cell
 
On Aug 5, 10:45 am, "Michael Slater" wrote:

I'm using the following formula in cell C3:
=INDEX(LastName,MATCH(A3,EmpID,0))

When I type in an employee ID in A3, his/her last name shows in C3.
However, when there is no value in A3, C3 shows error "#N/A".
Is there a way to show a blank cell in C3 until a value is entered into A3?


Try:

=IF(A3="", "", INDEX(LastName,MATCH(A3,EmpID,0))


Michael Slater

Show a blank result in a cell when there is no value in the "Lookup" cell
 
Thank you,

That worked great!!

Mike


"joeu2004" wrote in message
oups.com...
On Aug 5, 10:45 am, "Michael Slater" wrote:

I'm using the following formula in cell C3:
=INDEX(LastName,MATCH(A3,EmpID,0))

When I type in an employee ID in A3, his/her last name shows in C3.
However, when there is no value in A3, C3 shows error "#N/A".
Is there a way to show a blank cell in C3 until a value is entered into
A3?


Try:

=IF(A3="", "", INDEX(LastName,MATCH(A3,EmpID,0))




All times are GMT +1. The time now is 02:07 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com