Difference Calculation Based On Other Column - Reset Based On Non-Zero Value

Apr 4, 2014

I require calculating difference between two columns. (Actual and Estimated).

Difference between these two numbers are calculated in third column, but it is reset every time actual number is non-zero.

Scenario:-
-Estimated Numbers are always followed by an actual number.
-After actual number is obtained, estimated numbers till that date will be added and deducted from actual number.
-After this, again estimated number will be added till next actual number is obtained for deduction.

If estimated number is not followed by actual number, then no need for difference calculation.

View 3 Replies


ADVERTISEMENT

Hide Based On Time Difference Column

Mar 2, 2008

Have 2 columns with time values and the third showing the time difference ( no Problems). what to hide the row if the time diff is > 2 seconds? (problem) What would be the best why to do this

{Sub TimeDiff()
Dim i As Integer
Dim timevalue As Date
timevalue = "00:00.20"
Application. ScreenUpdating = False
With ActiveWorkbook. Sheets("Racing")
For i = 4 To . Range("M1") - 1
If .Range("P" & i) > timevalue And Rows(i).EntireRow.Hidden = False And .Range("P" & i) <> "" Then
Rows(i).EntireRow.Hidden = True
End If
Next i
End With
Application.ScreenUpdating = True
End Sub

View 2 Replies View Related

How To Pick Name From Column Based Value Difference In Column B

Dec 12, 2013

I have data like this:

NameRank
pietro30
fabri35
mauri60
andrea45
luigi50
anna90
federica100
julia120

Now I want to pick names from column A with rank difference between name should equal to 30.

Expected result

NameRank
pietro30
mauri60
anna90
julia120

View 7 Replies View Related

Reset Values Based On Dropdown?

Feb 11, 2014

I have a sheet which shows values by month across several years (sample attached). There are two options in cell A2, 'Alive' and 'Dead'.

I'm trying to find a way, either using a macro or not if it can be done without so that, should the user select 'Dead' from cell A2, that all the values in B2:M2 and O2:Z2 are set to zero. However, I need some way of remembering these values because there may be instances when the user then decides to change Cell A2 back to 'Alive' (and they still need to be able to change the value in any cell at any time) and if they do that, I need the numbers shown in B2:M2 and O2:Z2 to be restored to their last set of values. I assume they somehow need to be stored in an array, but I have no idea how to achieve this in reality.

It should be noted that the same will apply to every row in the sheet of which there will be around 3,000, so this needs to work on a row by row basis and there will be 4 years worth of data, rather than the two on the attached sample.

View 2 Replies View Related

Reset Cell Value Based On Two Conditions

Mar 10, 2009

I am trying to build a spreadsheet that tallies hours worked and hours available for the next day. The key to this spreadsheet is the number 70. A worker can accumulate no more then 70 hours in an 8 day period, however after any day with no hours worked the rule resets to 70 hours available again. I have attached a sample spreadsheet so you can see how this should work.

View 9 Replies View Related

Running Total To Reset Based On Criteria

Jan 1, 2008

Have a sample file attached : sample2.xls

What I want to do is - Column H shows my current position, and column L shows the p&l.

I would like excel to calculate the p&l for each position, and put the results in column M.

For example: H3 is the opening of a new position, as H2 shows the current position as zero, and H4 is not equal to zero. The position was added to in H4, and I'm now holding 2. The entire position was sold in H5, and my current position is back to zero. I would like excel to then show in M5, the sum of H3,H4 and H5, and then start the calculation again, and keep doing so down the entire column. If there was only 3 p&l cells for each position, it wouldn't have been a problem for me to get it done, but unfortunately, they can vary quite a bit.

View 9 Replies View Related

Formula To Reset A Count Based On Cell Value

Feb 2, 2009

I've found a # of threads on this subject but have been unable to find the function I need.

I've got a spreadsheet (attached) to calculate vacation time, but I can't figure out how to make the used time reset on an anniversay date. For example, if Employee 1 has earned 80 hours of vacation but only used 40 by his 4 year anniversary date, how do I make unused time roll back to 80 the day of his anniversary?

Here's the structure: 2 Personal days given Jan. 1, then 2 more on July 1 to employees here at least 6 months. Those whose 6 months fall after or between are awarded 2 days on their anniversary then accrue as normal. Unused personal days are lost at the end of the year. Vacation time is 40 hours after 1 year, 80 hours at 3 yrs, then 120 hours at 5+.

View 9 Replies View Related

Running Total To Reset Based On Criteria

Jan 1, 2008

Have a sample file attached, and what I want to do is as follows-

Column H shows my current position, and column L shows the p&l.

I would like excel to calculate the p&l for each position, and put the results in column M.

For example,

H3 is the opening of a new position, as H2 shows the current position as zero, and H4 is not equal to zero. The position was added to in H4, and I'm now holding 2. The entire position was sold in H5, and my current position is back to zero. I would like excel to then show in M5, the sum of H3,H4 and H5, and then start the calculation again, and keep doing so down the entire column. If there was only 3 p&l cells for each position, it wouldn't have been a problem for me to get it done, but unfortunately, they can vary quite a bit, and I have no idea how to do it

View 9 Replies View Related

Reset Dropdown Lists Based On Other Inputs / Cells

Jul 1, 2009

Trying to create a dynamic costing spreadsheet, where the user has to make multiple selections from many dropdown lists, all of which end up showing a total cost.

So far I have managed to create relatively dynamic lists, so that the choice in one cell will dictate what options are available in the next.

But if a user selects an options form all the dropdowns, and then decides to go back and modify a previous option to something else, the effected dropdown lists do not change until you click on the drop down arrow again and see the options available have changed.

Let me try and simplify...
'Menu 1' has two option: 'A' and 'B'.
If 'A' is chosen, then the next menu, 'Menu 2', will have options '1' and '2'.
If 'B' is chosen from 'Menu 1', then the options in 'Menu 2' will be '3' and '4'.
Lets say the user chose 'A' from 'Menu 1' and then '1' from 'Menu 2'... AND THEN went back and changed their choice in 'Menu 1' to 'B'....
'Menu 2' will still be displaying '1', even though the options are only '3' and '4'.

Can I make the dependant menu's either reset or blank or highlight to show that a change made somewhere else has made them currently invalid

View 10 Replies View Related

Macro To Transfer Data From One Sheet To Another Based On Date And Reset Fields

Jul 16, 2014

I am currently working on a workbook to have employees fill in data on what tasks they compelted for the day, and how long it took. There are 5 colums (for this purpose) Task, Description, Time, Required to complete, Completed. The tasks are predefined and listed out in each row. There is also a space for employees to select the date they are entering the data for.

I would like to have a macro that is linked to a submit button and when pressed populates this data into a database on another sheet. This database is split into two sheets (1 with time and one with tasks required/compelted). Each sheet has the list of tasks going down a cloum on the left, and dates along a row on the top. When the employee presses submit I would like this data to popuplate in the coresponding date and task fields and then reset the form on sheet 1 to all 0's.

View 1 Replies View Related

Calculate Difference Based On Criteria

May 5, 2013

I have a number which consist of 12 digits such as 765432123345. The first two digits denotes the year. I need to create a formula in the next column to calculate the difference in years by comparing to the current year of 2013. In this scenario, the difference will be 37. Is there a way to do this?

View 5 Replies View Related

Find Difference Between Two Columns Based On Their Names

Apr 15, 2014

Reference the attached excel audit example. Column F highlighted in Yellow is finding the difference between "Authorized Post Allow" D9 "Post Allowance" B9 . The Column location of the two Columns changes on each audit. This means I have to manually fix the formula in Column F every time. Is there a formula that would find the difference between these two columns based on their names "Post Allowance" and "Authorized Post Allow" preventing me from manully fixing the formula.

View 2 Replies View Related

Find Difference In 2 Values Based On VLOOKUP

Jun 20, 2014

This is probably easier than I'm making it on myself. I would like a formula that would find the value in D2 of the current sheet on a sheet named 6-19 in D:D, then take the value from L:L in that row and subtract it from L2 of the current sheet.

I've attached an example workbook : Cost Calc Upload.xlsx‎

View 1 Replies View Related

Check Distance Difference Based On Criteria

Feb 8, 2010

I have a Point A to Point B with the distance.

1. user can set a adjustable distance in cell J1. e.g 2000

2. User select Point A.

3. User select Point B

4. Then list out all the Point C where distance diff between Point A and Point B all within 2000.

View 14 Replies View Related

Conditional Formatting Based On A Percentage Difference

Apr 3, 2009

Using conditional formatting i am trying to write a formula that changes colour on the percentage difference of another cell.

An example would be if cell A1 contained a target of 5% in cell A2 would be an actual. If cell A2 is equal to A1 or better then it would be green. If cell A2 was within 10% less of A1 (i.e 4.5%-4.99%) then amber and red for the target minus 10% (i.e <4.49%)

I want to do this as a conditional formatting formula as the target figure will change but 10% difference will remain the same.

View 5 Replies View Related

Calculating Time Difference Based On Row Criteria?

Jul 30, 2012

I am conducting some analysis on alarm data of certain devices and am looking for creating a VBA algorithm that will do the following (refer to the table below for example data)

I want identify an asset in alarm (Column F) and based on its asset ID (Column C) and Fault Description (Column D) then find the row when the asset with the same asset ID and fault description returns to an 'ok' Asset State. After the row where the same asset ID and Fault description is found where the asset state returns to 'ok', I want to calculate the total alarm time based on the difference between when the asset ID and Fault description goes from 'Alarm' State to 'OK' state from DateandTime Column.

I want the result to be populated in a new worksheet that displays data with the following column headings as a result of the above calculations: Date, Asset ID, Asset Description, Fault Description, Alarm Time

I have added an additional column to show the type of output I am after.

There are up to 20,000 rows of data I want to perform the above calculation on.

A
B
C
D

[Code]....

View 2 Replies View Related

Display Result Based On Time Difference

Feb 15, 2008

I want to make a formula based on 2 times ex: 10:07:00 and 10:09:00. This formula should display "intime" if the diference between both is under 20 minutes, "outime" if the diference is above 20 minutes and it should display "error" if the time is under 0 minutes (this will only happen when someone makes a mistake typing in the time. For example 10:37:00 and 10:36:00)

View 3 Replies View Related

Conditional Formatting Based On Difference Value Between Figures In Two Cells?

Apr 10, 2014

I would like to use conditional formatting to mark cells with arrows depending on the difference between the values in those cells and figures from different cells. Namely, I have percentage values in column A and B. I need cells in column B to be marked with arrows (up, right or down) when the difference between value B and A is bigger than 2%, bigger than 0 but smaller than 2%, and smaller than 0 respectively (see the spreadsheet attached).

View 2 Replies View Related

Variable Cell Reference Based On Minimum Difference

Feb 12, 2010

I have a monitoring system that records a data point with a date/time stamp several times a day at random intervals. For each reading I want to calculate the change compared to the first reading that was more than 24 hours ago, which could be anywhere from 1 to 20 rows above the current one. Hence with the timestamp in col A and the value in col B, the formula in col C, for example cell C20, needs to read something like =B20-Bxyz, where xyz is the row number of the first reading that is more than 24 hours, i.e the first row xyz where A20-Axyz >1.

View 4 Replies View Related

Create Numeric Series Based On Difference Between 2 Columns

Apr 23, 2008

I have a small sheet that has a number in Column A and a larger number in Column B along with some data in Columns C and D. I wish to make a separate sheet that has rows numbered using the numerical range from Column A and Column B along with the data from Columns C & D

View 2 Replies View Related

Automatically Create Columns Based On Difference Between Two Dates

May 2, 2008

I have been perusing various Excel sites in hopes of finding a macro or function that can create columns based upon two dates input into specific cells. My ultimate goal is to use this macro or automated function so that when the user inputs the dates, the columns would automatically be created for them, rather than having them do it manually.

ideally, the 'start' and 'finish' dates are named cells and the macro could determine the difference between the two and automatically insert columns to the left of a ' Totals' column.

View 9 Replies View Related

Color Cells Based On Difference In Months Of Dates

May 14, 2008

I have dates in Column D (mm/dd/yyyy). I'm trying to write a macro to compare the date in any cell in Column D to the current date. Then, if the date in that cell is within a month of the current date, color it red. If the date is within two months, color it orange. Etc, for up to six months. I've read up a little on dates in VBA, but I'm pretty lost.

View 4 Replies View Related

Calculation Based On Date

Jul 16, 2013

How calculation can be made based on the date. I have 2 sheet (MATTER and REPORT). All productions made within sheet MATTER. Then I will produce report to be printed in sheet REPORT. I only include the date and calculation every matter will be automatically made based on date and item.

View 6 Replies View Related

Calculation Based On % Of Cells

Oct 29, 2008

I need a formula that I can place in, lets say, Cell A1 that will reference Cells B1, B2, B3 and C1, C2, C3. These all have numbers & %'s in them. However, I want to "weight" the B cells by the percentages in C cells. The problem I am having is that when I change the %'s nothing is changing in the output...almost like I was doing nothing but averaging B1:B3 without the % to adjust.

This is how I envision it, but my calculation may be wrong of course :
A1 = average(sum(B1,B2,B3)*C1, sum(B1,B2,B3)*C2, sum(B1,B2,B3)*C3)

The Goal:

This would allow me to change the output depending on the percentage. So if I am looking at days to an appointment and the B cells represent areas of a city: B1 = 10, B2 = 5, B3 = 2 the average would be 5.6, however, I know that B1 city has more "weight" to it with our customer base so I want B1 to be closer to what will show as days out (which is obviously important as 10 days is not good). So I would assign C1 = 60%, C2 = 30%, C3 = 10%. This should pull the average more to 7 or 8 as it would lean more towards the B1 value. I hope this makes sense.

I did try going more of a route where I did something like =average(B1*C1,B2*C2,B3*C3) but that lowered all the original values instead and averaged them instead of pushing the number more towards the higher weighted % of B1 cell value. I can send an example spreadsheet if I am losing anyone.

View 8 Replies View Related

Calculation Based On Variable

Jun 28, 2006

Im trying to access data from 2 different cells (say A1, B1), its for calculating transformer hotspots. The cooling method of the transformer is naturaly air cooled oil.. until the winding temp reaches 75C ( I have winding temp data laid out on a column) then the fans come on and some constants in the formula change (need to read from the other cell, say B1) so it switches, but the fans stay on UNTIL the winding temp is 50C and then go off, so the characteristics change back to the previous one, so I need to switch back. How do I go about doing this... my current method starts working when it reaches 50 instead of waiting the temp to go to 75 then fall to 50 then do it... im a bit confused.. maybe i shouldnt be doing this on excel... ow well

View 9 Replies View Related

Calculation Based On Criteria

Jul 25, 2006

I'm trying to calculate a price for any given mileage. The pricing strategy is as follows:

For any journey 2 miles or less, the price is £9
For any journey between 2 or 3 miles, the price is £10
For any journey above 3 miles, the price is £10 for the first 3 miles plus £2 for every additional mile.

So, for example, the price of a 1.5 mile journey is £9 and the price of a 3.5 mile journey is £11.

View 6 Replies View Related

Calculation Based On Cell Value

Dec 17, 2007

I tried all those search and have no idea what to look for, sorry.

I have attached a single sheet with Footpath Budget for you to see.

In J6, we put in Y or N for Yes or No if there's a nature strip along the footpath.

Now, in cell G49 gives us the total square meters of nature strip.

What I want to do is if I put N in cell J6, cell G49 should be empty or zero because N means there's no nature strip. But if I put Y in J6, then cell G49 can give us total squares from cell C43.

So what formulas can I put in cell G49?

View 3 Replies View Related

Trying To Create Calculation Based On Particular Criteria

Jan 29, 2014

I have 2 worksheets with data. One of them is a bench mark template or expected times to complete devices based on batch size and product. The other worksheet is a report generated that shows the actual time techs worked on batches of equipment by product type. I am trying to automate a report that I will need to run every week. I have most of it automated but need some calculations. I want to calculated the expected time to complete the work, based on the data provided in the benchmark worksheet.

I do not want to use an average, and I want to use the expected time of completion based on batch size and product relative to the tech report. Column T is highlighted and where I want this formula to be entered. So if the Total Batch items is 1, then the expected calculation uses that time relative to the product and then multiplies that number to the batch size. Or if the batch size is 3, then it uses the time relative to a batch size of 3 and then multiplies that number by the batch size on the tech report and is entered in the highlighted column.

I have attached the workbook I am working with : Production Report.xlsx‎

View 9 Replies View Related

Script For Calculation Of Sum Based On Two Conditions

Feb 21, 2014

I have the following spreadsheet as an example:

A
B
C
D
E
F
G
H

1
Article/hours
10
27
33
15
33
40
40

[Code] ........

Column A contains codes for certain work activities.Row 1, from Column B and beyond contains number of worked hours.The matrix is populated with letter "D" to mark activity for particular work code for particular amount of worked hours.

My goal is to have a formula/script that analyzes this matrix, and returns a total amount of worked hours per work code. In other words, if a cell contains the letter "D", the amount of hours in Row1 for that particular column should be added to the total amount for that particular code, let's say code "501" as an example. For this example, the result should be a cell, lets say "A8", that contains the total amount of hours spent on code 501: in this example - 213 hours.

View 5 Replies View Related

Calculation Based On Colored Cells

Dec 4, 2008

i have a sheet which has name of students (A2:A10), B1:E1 has project name. and the projects are catagorised by color red=high,green=medium, yello=low. i have given weightage to these color red=80%, green=50%, yello=20%.
similarly the involvment of the students in each project is shown by these three color in respective cell. like B2 is red, C2 is red,D2 is blank, E2 is green. (the weightage is same as above). in column F i want the total utilisation of each student, which is simply sum of product of weightage given to these colors.
e.g.

project 1project 2project 3project 4utilisationsam1.38joe0.54nick0.72

what i want is to calculate this utilisation number, but i want my sheet to be shown in the same color format.
i am sure that there is some solution for this.

View 9 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved