Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 04-15-2017, 09:24 AM
DaliKibran DaliKibran is offline Combine Indirect and If formula? Windows 10 Combine Indirect and If formula? Office 2016
Novice
Combine Indirect and If formula?
 
Join Date: Apr 2017
Posts: 2
DaliKibran is on a distinguished road
Default Combine Indirect and If formula?

I have a simple inventory spreadsheet for my locations to enter inventories on. I'm using a simple IF formula to present to them a number for reorder if the inventory is below the par value for that item, and present them a blank cell if the inventory is at or above par.

Currently, employees have to update the formula when they insert a row to enter the new inventory. I need the employees to be able to insert a line above the last inventory taken (above row 11 in the image) and for the formula to "stick" with the row (11) instead of updating to the row below the insertion (where it was originally referencing). Every time I insert, the formula updates to row 12. I've tried absolutes, but that does not help - it still updates to row 12.

I've read online that you can use indirect to achieve this, but every time I try to combine If and Indirect formula, I get an #REF! error. I don't have any experience with Indirect.

Any help would be appreciated!
Attached Images
File Type: jpg Simple IF.jpg (107.3 KB, 13 views)
File Type: jpg With Indirect.jpg (117.6 KB, 13 views)
Reply With Quote
  #2  
Old 04-15-2017, 10:24 AM
xor xor is offline Combine Indirect and If formula? Windows 10 Combine Indirect and If formula? Office 2016
Expert
 
Join Date: Oct 2015
Posts: 1,097
xor is a name known to allxor is a name known to allxor is a name known to allxor is a name known to allxor is a name known to allxor is a name known to all
Default

If I understand what you want:

=IF(INDIRECT("P7")-INDIRECT("P11")<1,"",INDIRECT("P7")-INDIRECT("P11")) or better

=if(INDEX(P:P,7)-INDEX(P:P,11)<1;"",INDEX(P:P,7)-INDEX(P:P,11)

Better because INDEX contrary to INDIRECT is non-volatile. Volatile functions may make Excel slow if you work with large models.

Last edited by xor; 04-15-2017 at 11:40 PM.
Reply With Quote
  #3  
Old 04-16-2017, 11:05 AM
DaliKibran DaliKibran is offline Combine Indirect and If formula? Windows 10 Combine Indirect and If formula? Office 2016
Novice
Combine Indirect and If formula?
 
Join Date: Apr 2017
Posts: 2
DaliKibran is on a distinguished road
Default

That's the ticket, xor! They both work perfectly! (Excel said there was an error in the index formula and corrected - I think it was the semicolon.)

I'll take your advise and use the second just in case. Thank you so much!
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Indirect with hlookup jamesjts Excel 3 01-05-2016 09:13 AM
Indirect AND OR Formula Help del_piero_3 Excel 3 09-18-2015 02:58 PM
Combine Indirect and If formula? Indirect Reference? tinfanide Excel 2 08-28-2015 05:11 PM
Combine Indirect and If formula? Indirect Formula with dynamic rows bluionz Excel 1 03-13-2014 11:00 AM
Indirect zleyphox Excel 1 02-11-2010 09:57 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 08:54 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft