Tennisguuy
Well-known Member
- Joined
- Oct 17, 2007
- Messages
- 564
- Office Version
- 2016
- Platform
- Windows
I have the following formula in cell G22 and it works fine and provides the correct answer
IF(B22="","",IF(AND(V22<>"",W22<=6,W22<>""),VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)*VLOOKUP(V22,Indicated!$I$93:$J$99,2,FALSE),IF(AND(V22<>"",W22>6,W22<=10,W22<>""),VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)*VLOOKUP(V22,Indicated!$I$93:$J$99,2,FALSE)*0.98,IF(AND(V22<>"",W22>10,W22<>""),VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)*VLOOKUP(V22,Indicated!$I$93:$J$99,2,FALSE)*0.95,VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)))))
I want to revise the formula so that if the value in B22 is equal to extra heavy truck or truck tractor I want the minimum to be 2,500
I tried revising it to this but it's not working the way I want
IF(B22="","",IF(AND(V22<>"",W22<=6,W22<>""),IF(MIN(OR(B22="Extra Heavy Trucks-Over 45,000 lbs",B22="Truck-Tractors"),VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)*VLOOKUP(V22,Indicated!$I$93:$J$99,2,FALSE),2500),IF(AND(V22<>"",W22>6,W22<=10,W22<>""),IF(MIN(OR(B22="Extra Heavy Trucks-Over 45,000 lbs",B22="Truck-Tractors"),VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)*VLOOKUP(V22,Indicated!$I$93:$J$99,2,FALSE)*0.98,IF(AND(V22<>"",W22>10,W22<>""),VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)*VLOOKUP(V22,Indicated!$I$93:$J$99,2,FALSE)*0.95,VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)))))),2500))
I am getting an error.
IF(B22="","",IF(AND(V22<>"",W22<=6,W22<>""),VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)*VLOOKUP(V22,Indicated!$I$93:$J$99,2,FALSE),IF(AND(V22<>"",W22>6,W22<=10,W22<>""),VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)*VLOOKUP(V22,Indicated!$I$93:$J$99,2,FALSE)*0.98,IF(AND(V22<>"",W22>10,W22<>""),VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)*VLOOKUP(V22,Indicated!$I$93:$J$99,2,FALSE)*0.95,VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)))))
I want to revise the formula so that if the value in B22 is equal to extra heavy truck or truck tractor I want the minimum to be 2,500
I tried revising it to this but it's not working the way I want
IF(B22="","",IF(AND(V22<>"",W22<=6,W22<>""),IF(MIN(OR(B22="Extra Heavy Trucks-Over 45,000 lbs",B22="Truck-Tractors"),VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)*VLOOKUP(V22,Indicated!$I$93:$J$99,2,FALSE),2500),IF(AND(V22<>"",W22>6,W22<=10,W22<>""),IF(MIN(OR(B22="Extra Heavy Trucks-Over 45,000 lbs",B22="Truck-Tractors"),VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)*VLOOKUP(V22,Indicated!$I$93:$J$99,2,FALSE)*0.98,IF(AND(V22<>"",W22>10,W22<>""),VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)*VLOOKUP(V22,Indicated!$I$93:$J$99,2,FALSE)*0.95,VLOOKUP(A22,Indicated!$Z$8:$AD$56,5,FALSE)*VLOOKUP(B22,Indicated!$I$83:$J$89,2,FALSE)))))),2500))
I am getting an error.