# Getting Two Formulas To Work Together In Same Cell

Oct 10, 2006

i have the following formulas that work perfectly seperatly

=MAX(0,(E28-D28-"0:45")*24-F28)

=IF(C28=\$C\$70,C28=\$C\$72),2,0)

but it is imperative that i get them to show there results in the same cell.

neither are used at the same time, only one result is required depending on what is needed.

i did try putting them together as follows but did not work

=MAX(0,(E28-D28-"0:45")*24-F28),IF(C28=\$C\$70,C28=\$C\$72),2,0)

## Formatting/formulas To Work

Jan 19, 2010

I'm trying to get some formatting/formulas to work, but apparently I'm not doing it right (otherwise, I wouldn't be here ):

1. Column A has dates. I want Column A_ to be red if the date is a week old or more from today's date, and white if it is not.

2. Column A has dates, and column B has dollar values. I want three four summations:
-Total dollar value from dates a week old from today's date
-Total dollar value from dates 2 weeks old from today's dates
-Total dollar value a month old from today's date
-Total dollar value year to date

## HLOOKUP To Work With Cells Containing Formulas

Dec 8, 2013

I have a niggling problem with a worksheet when using Hlookup to return a value from a range of cells it is coming up with blanks when there is data in the range.

There is only ever one row cell containing text in the specified range and i need this to be returned in another column.

The problem with the hlookup formula i am using is that it will not work if cells contain formulas and in the range i am working on all cells contain formulas.

I know this formula works if there is text without a formula in the cell range, as soon as it hits a cell with a formula though it won't work.

I have attached the sheet : Book4.xlsx

From j138 there is one cell with text i wish to be returned in column q for each row. E.g., in q1 the first cell text returned would be khawatim. q2 should contain cantor etc etc.

## Moved Document Now Formulas Don't Work?

Jul 31, 2013

I have created two documents. One document (A) is my worksheet where I input data, the second document (B) is my spreadsheet where it comprises all my data into the fields I want. I have completed both documents on computer (1) and now need to transfer it to another computer (2). However my formulas no longer function after I move the document (A) from computer (1) to computer (2). Is there a way for me to work around this? Do I need to transfer the spreadsheet (B) to computer (2) in order for them to function correctly? How can I make it so I have the worksheet (A) on computer (1) enter data correctly into the spreadsheet (B) on computer (2)?

## How To Make IF Work On Formulas And Not Values

Nov 18, 2013

I've developed a spreadsheet that shows what errors people made in their spreadsheets. I compare cell A1 in spreadsheet 1 (original) against cell A1 in spreadsheet 2 (final), in spreadsheet 3. Spreadsheet 3 shows a "-" if the cell they wrote was OK, and shows the new, correct value if they made an error, as follows:

=IF('Final'!A5='Original'!A5, "-",'Final'!A5)

The problem is, this only works if I take the original spreadsheets, which contain formulae in each cell, and paste them into a new spreadsheet using paste values.

Is it possible for the IF function to search the formula in a cell, and not the value?

## Will Array Formulas Work In =AVERAGE()

Dec 28, 2007

This formula is returning 0.2578 when it should return 2.473

{=AVERAGE(('Data-Design'!E2:E6000)*('Data-Design'!Q2:Q6000=1))}

What am I not understanding?

I want the average of column E when column Q=1

## Formulas No Longer Work After Converting To Table

Apr 27, 2013

I'm working on a spreadsheet which will sum values from two source worksheets based on the month and year in certain columns. I put together a summary worksheet and was able to successfully pull the data I wanted. So my next step was to convert the Summary data into a table (because I prefer the aesthetic value of the "greenbar" effect in Excel tables). But as soon as I converted the cells to a table, the formulas returned nothing.

After playing around with it, I determined that the problem seems to be the fact that I use the year criteria as a cell reference (that way, I can later change the year in one cell and update all the dependent formula). I've got "2013" in Cell A1 in General format, and all the formulas use a YEAR=\$A\$1 criterion. I found out that if I changed the formulas to YEAR=2013 instead of using the cell reference, I got the desired result again. But I cannot quite understand why changing the data into a table would alter the way Excel interprets the formula (plus, I still want to be able to change the year by updating one single cell).

## CUSTOM SORTING Will Not Work On Table With INDEX Formulas

Jan 28, 2014

Problem we are having with sorting a table.

The table (A1:E10) was created by pulling data from another worksheet using INDEX and ARRAY formulas.

We inserted 6 columns to move the table over to G1:K10 (used column F to space the two tables).

We then duplicated the table: cell A1=G1, B1=H1, ...., E1=K1 and dragged the formulas down. We now have a duplicate table that we want to sort.

We choose CUSTOM SORT and choose 2 levels of sorting ... column A and column C.

PROBLEM: The ARRAY formulation evidently overrides the sort function because the table remains as it was when the sorting command is executed.

Is there a way to bring the data from table G1:K10 over to table A1:E10 in a manner that will allow sorting??

## Capture And Calculate Data Based On Work Week In VBA Or Formulas

Jul 21, 2014

I have a requirements to capture the data and calculate the qty based on the defined work week. How to to this in vba macro or a formulas. I'll giving a sample data as reference. In my sample data i have already the formulas
but i wanted to automate the work week calculation specially if the number of days in a month has been change.

Btw, the values of every column is came from other worksheet. i copy paste this data as my sample.

For ex : Today is July and it has 31 days, the 31 days will be distributed to the defined workweek and calculate the contents of the corresponding column.

here is the distribution of columns per week as reference.

(31 days)
wk1 - Day1 to Day8 (8 colums)
wk2 - Day9 to Day16 (8 colums)
wk3 - Day17 to Day24 (8)
wk4 - Day25 to day 31 (7) columns

(30 days)
wk1 - Day1 to Day8 (8 colums)
wk2 - Day9 to Day16 (8 colums)
wk3 - Day17 to Day23 (7)
wk4 - Day23 to day 30 (7) columns

## Using Cell References In File Paths For Formulas To Create Dynamic Formulas

Dec 3, 2013

I am using a lot of linked reports that have to be rewritten each month. For example smaller formulas look like this:

=('S:PUBLICProductionJob CardsMOLDING201311 November[440A SIDE SPOILER JOB CARD.xls]Production Parts'!B\$228*2)+'S:PUBLICProductionJob CardsMOLDING201311 November[440A SIDE SPOILER JOB CARD.xls]Production Parts'!B\$262+'S:PUBLICProductionJob CardsMOLDING201311 November[440A SIDE SPOILER JOB CARD.xls]Production Parts'!B\$292

What I want to do is extract the file path from the above formula and make it a composite of several cell references.

So what I need is to have a cell where they can change the month and another where we can change the year. So I set up several named cells that look like this:

_MONTH =11 November
_YEAR =2013
_JOBCARD ='S:PUBLICProductionJob CardsMOLDING
_PATH =_JOBCARD & _YEAR &"" &_MONTH

I tried several versions, I am hoping for something like this:

=('_PATH &"[440A SIDE SPOILER JOB CARD.xls]"Production Parts'!B\$228*2)+'_PATH &"[440A SIDE SPOILER JOB CARD.xls]"Production Parts'!B\$262+'_PATH &"[440A SIDE SPOILER JOB CARD.xls]"Production Parts'!B\$292

## Work Out A Formula For My Spreadsheet Which I Use To Work Out Cutting Lists For Timber Frames

Jan 11, 2009

i need to work out a formula for my spreadsheet which I use to work out cutting lists for timber frames. I need it to work out if the width of a job is for eg 2400mm i need to work out how many timber studs I need so the space between each stud is between 400mm and 500mm and this will need to work for a range of different sizes of frames. I have it written at the moment and it just devides the width by 400 and gives me a amount of studs but it would work much better if it could space them between 400 & 500.

## Work Accurately With Times To Calculate The Work Progress Of The People In The Workshop

Mar 3, 2009

In a project i am compiling i need to work accurately with times to calculate the work progress of the people in the workshop thus....here goes....

I have in work book #1 (7) sheets mon to fri + complete week + a sheet where all job numbers are collected.

From monday to friday the workmen log their times as a start time and a end time. This has to be then calculated to a total hours:mins spent per job, wich in turn then has to be calculated to a total hours:mins spent per day. And the on the complete week sheet recalculated as a total time worked per week.

## How To Get A Macro To Work With Any Work Book Name

Aug 24, 2009

i have a made a macro that copies info to a new sheet now that is working great but if i change the name of the work book it wont work any more so i need the macro to work with what ever name i give the workbook

the current name is

AVERAGE PRICE (update 2009) Mimmos Armico 170809.xls

i have attached the code in notepad ...

## Make To Display (0), Instead Of (-0,02) When I Just Do Other Work Than Cad Work

Feb 13, 2010

In column J, Cad Hrs. How to make to display (0), instead of (-0,02) when I just do other work than Cad Work? I need to separate type of work according to price hour, overtime, and so on.

## IF Formula Only Work If Particular Cell Is Less Than 50

Aug 7, 2014

See the attached workbook.

Please edit the formula in column B so that it only gives a BINGO if the adjacent cell in column G is less than 51.

So cell M16 should not be a BINGO because cell G16 is not less than 51.

Attached Files : Book1.xlsx‎

## Cell Limit Work Around?

Sep 16, 2009

Is there a way to make the find and replace function not stop when a cell is too large? Instead, make it pass over the large cells and move on to the next cells? Is there a function that gives the number of characters in a cell? If so, one could sort by cell size and then work around the cells that are too large?

## Macro To Work When Cell Changes Value

Sep 5, 2008

Everytime a cell (say B18) changes value I want the following to happen:

If it changes to "Annual" I want row 20 to ungroup

If it changes to "Quarterly" I want rows 22-25 to ungroup

If it changes to "Monthly" I want rows 27-38 to ungroup

From what I can see on other discussion groups I need to enter a code on the worksheet from view code... but I cant work out the code that I would need to enter.

## Macro To Work Out Top 3 Cell Occurrences

Oct 16, 2013

I have a database full of part numbers for example 0EV2310A06G01JU:S5065

These can vary to having a vareity of symbols/letters/numbers (I am not sure if this makes a difference!)

writing a macro to run a report to show the top three reoccuring partnumbers.

The spreadsheet is currently 1845 cells big but this data will change on a weekly basis, the layout will however remain the same. The column that the part numbers are in is column A.

Is a macro the right way to be approaching this if the data is going to be changing on a weekly basis?

## Does VLOOKUP Not Work If Too Many Characters In Cell

Sep 25, 2007

I have a VLOOKUP formula that works when searching some cells but not others when both cases should work.

Q: Does VLOOKUP have a certain maximum amount of characters it can search? If a cell contains more than this amount of characters will VLOOKUP not work?

This is what seems to be happening on my spreadsheet. The VLOOKUPS that refer to the cells with more than the average amount of characters seem to fail. The same happens with INDEX.

## Change On Events Fails To Work On 1st Use Of A Cell

Jul 27, 2013

I have set up a selection change routine which works if the cell has previously been used or if you make an entry and then change it again. I have tried to delete the empty cells 1st and then save the document, when opening the document it I enter a value in a previosly unused cell the change function does not appear to be called. There is an auto open routine that runs as well, there is more code in use but it fails at the start point.

VB:
Sub Auto_Open()
'
' Auto_Open Macro
'
'
Application.EnableEvents = True

[Code] ......

## IF Formula - Add A Number To A Cell For Work Breaks?

May 28, 2014

I am trying to add a number to a cell for work breaks. Below is what I am trying to do:

If F3 is < 4 then 0
If F3 is > 4 but < 6 then .25
If F3 is < 6 then .50

## VLOOKUP Wont Work If The Cell Contains A Formula

Mar 27, 2009

I have a VLOOKUP formula, so when the cell above (C5) has a value, it returns the value from a defined list. Simple so far and it works great when I manually input the value in the cell (C5).

The problem occurs when I change C5 to contain an AVERAGE formula? Any ideas why it will only work when there is a plain old value in there, but not a formula?

This is the VLOOKUP formula I'm using:

## Macro Does Not Work From Any Selected Cell On Spreadsheet?

May 21, 2014

I created a very simple macro, which actually works.

There is a button on my spreadsheet, so the user can launch the macro using this button.

[ Code] .......

At the moment the user clicks on the button, the part of the macro which is hiding the rows will not take place if the cell activated at the moment of launching the macro is in the range below :

The table on my Excel sheet covers range A5:E49

If the active cell is anywhere in A6:49 or C5:D24 or C25, the hiding part of the macro will not work. Launched from any other cells on the spreadsheet it works fine.

The rest works fine and I am not getting an error.

To solve this I just need to add the line Range("G9").Select and it will work.

But I would like to understand why it does not work from the cells given above. My sheet is not protected and I unlocked the cells just ion case.

## Work Out Time In And Out Based On Cell Format

Jan 14, 2009

I have a sheet that I want to calculate what time a shift starts based on a cell shading.

Basically Cells C6 and D6 need to be auto calculated based on the cells that are shaded from G6:L6

Look at the Attachment and you will see what I mean.

## Select First Empty Cell... Doesnt Work

Aug 10, 2009

I am using this code to select the first empty cell in column A.

## Date In Cell - Adding Work Days

Nov 11, 2011

I have a date in A2 7th Nov 2011

Column B is number weeks until next appointment - 4.
Column C is the answer Friday 2nd December if the normal result is a Saturday or Sunday then use Friday.

## Get Autofilter To Work Based On Cell Contents?

Jun 26, 2014

I am trying to get autofilter to work based on cell contents.

Code:
ActiveSheet.Range("\$C\$1:\$C\$18371").AutoFilter Field:=1, Criteria1:=">=1.5" _
, Operator:=xlAnd, Criteria2:="

## Formula To Work Where It Will Search A Single Cell

Feb 27, 2009

I am trying to get a formula to work where it will search a single cell (on a sheet called "Calls") to see if a particular code is in there, if so return a value using HLOOKUP from a table on a sheet called "Values". The problem I am having is how to use the wild card etc because everything I have tried returns an error...

The code I am trying (Without wild cards, because they all failed) is...

Code: ....

## Case Statements Only Work On Cell Selection

Jun 19, 2009

I've got the following code, which evaluates a sheet for the string "Event held", and then offsets multiple columns before adding several strings.

The second part of the code is what I can't get working correctly. Each cell containing the strings inserted by the offsets are set to change colour based on their contents.

What I want is for them to change colour as soon as the strings are offset, but at the moment, I have to click on each cell before the colour appears....

## Dropdown List (DV) Doesn't Work Same As Typing In Cell

Aug 26, 2013

I have written code in which cell color changes according to cell value. To change cell value I have used drop down list (Data/Validation/List). Main question/problem is code works well when cell value is changed by typing from keyboard only.

Code doesn't work when cell value is changed using drop down list.

Attached is the test file : Test_26082013.xls