Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Junior Member
 
Posts: 6
Default Formula to check presence of value between sheets

Hi guys,

I need some help to figure out the formula to be used on an inventory sheet.

I need to check if a certain value (text/numeric combo, eg. "POLP1003") appears in a specifici column on several different sheets and then to return a value of "No data" if the value does not appear at all.

The pseudo-formula I have so far is:

=IF(OR('Active Service'!C:C=A6; Spare!A:A=A6; 'In Repair'!A:A=A6; Retired!A:A=A6),,"No data")

(Where A6 is the cell containing the item name I am searching for)

eg. A6 = "POLP1003" I want to check for that value in Column C in one sheet, Column A in the next worksheet, Column A in the third worksheet and finally Column A in the fourth worksheet. If that value does not appear in any of the worksheets, I need, "No data".

Thanks.
  #2   Report Post  
Senior Member
 
Posts: 663
Default

Quote:
Originally Posted by Galant Koh View Post
Hi guys,

I need some help to figure out the formula to be used on an inventory sheet.

I need to check if a certain value (text/numeric combo, eg. "POLP1003") appears in a specifici column on several different sheets and then to return a value of "No data" if the value does not appear at all.

The pseudo-formula I have so far is:

=IF(OR('Active Service'!C:C=A6; Spare!A:A=A6; 'In Repair'!A:A=A6; Retired!A:A=A6),,"No data")

(Where A6 is the cell containing the item name I am searching for)

eg. A6 = "POLP1003" I want to check for that value in Column C in one sheet, Column A in the next worksheet, Column A in the third worksheet and finally Column A in the fourth worksheet. If that value does not appear in any of the worksheets, I need, "No data".

Thanks.
What do you want the result to be if the value in A6 IS found in one of the columns?

What about if it appears in more than one of the columns?
  #3   Report Post  
Junior Member
 
Posts: 6
Default

Quote:
Originally Posted by Spencer101 View Post
What do you want the result to be if the value in A6 IS found in one of the columns?

What about if it appears in more than one of the columns?
If a value is returned it can be left blank.

If a value appears more than once it doesn't matter. The idea of this formula is to check for the existence of a physical item in one or more locations where the item could move between locations. Therefore, if an item exists, it will appear on one of the lists. If it does not appear on the list then it means that it no longer exists and I need to be notified.
  #4   Report Post  
Senior Member
 
Posts: 663
Default

Quote:
Originally Posted by Galant Koh View Post
If a value is returned it can be left blank.

If a value appears more than once it doesn't matter. The idea of this formula is to check for the existence of a physical item in one or more locations where the item could move between locations. Therefore, if an item exists, it will appear on one of the lists. If it does not appear on the list then it means that it no longer exists and I need to be notified.
Have a look at the attached. This is one way to do it.
Attached Files
File Type: zip GalantKoh Example.zip (6.0 KB, 48 views)
  #5   Report Post  
Junior Member
 
Posts: 6
Default

Quote:
Originally Posted by Spencer101 View Post
Have a look at the attached. This is one way to do it.
Brilliant! Thank you for your help, especially so quickly!

Much appreciated!


  #6   Report Post  
Senior Member
 
Posts: 663
Default

Quote:
Originally Posted by Galant Koh View Post
Brilliant! Thank you for your help, especially so quickly!

Much appreciated!
Not a problem.
Glad to help :)
  #7   Report Post  
Junior Member
 
Posts: 6
Default

Quote:
Originally Posted by Spencer101 View Post
Not a problem.
Glad to help :)
Can I be a pain?

I know this isn't what I originally requested but now I've played with it an additional function would be useful.

Is it possible, instead of leaving the IF TRUE value blank, to have it return the name of the sheet on which the searched value (in this case A6) was found?

To summarise, if the value is false it will return "No data", but if the value is true, then it will return either, "Active Service", "Spare", "Retired", "In Repair", depending upon where the value was found?

That would be really helpful.

Thanks.
  #8   Report Post  
Member
 
Location: Bangalore
Posts: 41
Smile

Quote:
Originally Posted by Galant Koh View Post
Can I be a pain?

I know this isn't what I originally requested but now I've played with it an additional function would be useful.

Is it possible, instead of leaving the IF TRUE value blank, to have it return the name of the sheet on which the searched value (in this case A6) was found?

To summarise, if the value is false it will return "No data", but if the value is true, then it will return either, "Active Service", "Spare", "Retired", "In Repair", depending upon where the value was found?

That would be really helpful.

Thanks.
Hi,

Is it alright for you to use a VBA custom function which works in an exactly the same way. It is definitely possible to return what you are asking for. Here is a formula that would return the sheet name in the sheet it is used.
=RIGHT(CELL("filename",B1),LEN(CELL("filename",B1) )-FIND("]",CELL("filename",B1),1))

As you see it is a cumbersome process to get such a simple information from built in functions. Also looking at the existing way the formula is return there can be some issues later such as what happens when someone inserts a new sheet. You will have to modify your formula.

I would suggest a VBA function for such a task but want to check with you if you are happy with this before I can create a custom function for you.

Let me know your thoughts.

Prashant
  #9   Report Post  
Junior Member
 
Posts: 6
Default

Quote:
Originally Posted by jack_n_bub View Post
Hi,

Is it alright for you to use a VBA custom function which works in an exactly the same way. It is definitely possible to return what you are asking for. Here is a formula that would return the sheet name in the sheet it is used.
=RIGHT(CELL("filename",B1),LEN(CELL("filename",B1) )-FIND("]",CELL("filename",B1),1))

As you see it is a cumbersome process to get such a simple information from built in functions. Also looking at the existing way the formula is return there can be some issues later such as what happens when someone inserts a new sheet. You will have to modify your formula.


Prashant
EDIT - Okay, a bit of self-education and a custom VBA would be fine. Let me know if you need anything from me. This is really kind of you. Thank you!

Last edited by Galant Koh : November 9th 12 at 12:50 PM
  #10   Report Post  
Junior Member
 
Posts: 6
Default

Quote:
Originally Posted by Galant Koh View Post
EDIT - Okay, a bit of self-education and a custom VBA would be fine. Let me know if you need anything from me. This is really kind of you. Thank you!
Hi Jack, are you able to proceed with this?

If not, would anyone else able to help me out with a solution for this?

Thanks.
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Check for NON-presence of a string in another string G.P.N.L. c.v.a. Excel Worksheet Functions 4 December 11th 09 06:10 PM
Detect Presence Formula Ken Excel Worksheet Functions 6 September 12th 06 06:43 PM
please help me mark their presence. hirendra7158 Excel Worksheet Functions 3 March 13th 06 10:46 PM
count their presence hirendra7158 Excel Worksheet Functions 1 March 13th 06 08:41 PM
Sheet presence? Zurn[_32_] Excel Programming 5 March 9th 06 11:40 AM


All times are GMT +1. The time now is 06:58 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"