Date And Time Calculation Giving Incorrect Answer

Nov 21, 2011

The following formula seems to be incorrect. I typed in the times and dates to get the difference in hours, but my times are in 5 minute blocks, so the answer is given doesnt add up

Start DateFinsh date Hours15/11/2011 13:5017/11/2011 2:2536.58

View 3 Replies


ADVERTISEMENT

Mulitiplying In Formula Giving Incorrect Answer

Dec 20, 2009

I have a formula that is correct all the way up to adding the last *K9. here is an

example:

C9 a number 4 then add 1 to it which makes it 2 now * it by D9 which is the number 384 and the answer is 768 now * that by K9 which is 6 and you get 4608 I'm getting 2310 using this formula... =IF( C9=0, 0, C9+1*D9)*K9.

View 3 Replies View Related

Addition Calculation Not Giving Correct Answer

Feb 20, 2009

I have a workbook with calculations for a sale less the assorted fees and at the end giving the final amount from a sale.

I have noticed that some of the rows are not giving the correct amount in them.
In other words the addition of some columns in that row are not adding up correctly. It is only off by 1 cent (either over or under), but I can't figure out why.

I have the feeling that I am going to want to kick myself when someone explains this to me (I just know that I know the answer but for the life of me I can't right now).

View 2 Replies View Related

Lookup Sunset Time Based Onrecord Date - Incorrect Time Calculated

Mar 22, 2012

Consider this code:

'light eligibility
Dim facb As String
Dim sunset As Variant
[color=green]' check if facility has lights[color]
facb = WorksheetFunction.VLookup(RID, ds, 10, False) 'find facility code
If WorksheetFunction.VLookup(facb, fac, 6, False) = "Y" Then 'facility has lights
sunset = WorksheetFunction.VLookup(tempws.Range("A9"), sun, 2, False) 'lookup the sunset time based on the record's date

[Code] ......

This code checks the need for lights at a facility.

It first checks to see if the facility even has lights by cross-referencing a value in the record with a facilities database.

If it has lights, it then checks to see if they are needed. If the rental goes past the sunset time, then it needs lights. Sunset is determined by cross-referencing the date value in sheet1! A9, with the sunset database.

If it needs lights, variable lghtson is calculated equal to "sunset"-30 minutes.

As I step through this code:

WorksheetFunction.VLookup(facb, fac, 6, False) = "Y" Facility has lights.
Check to see if lights are needed.
sunset = WorksheetFunction.VLookup(tempws.Range("A9"), sun, 2, False)
sunset=0.879166666666667 which is 9:06PM. This is a proper value from the lookup.
If rental_end.value > sunset Then
rental_end (value from textbox) = "9:30 pm" , sunset=0.879166666666667. This is true, and Excel accepts it as true ...
lghtson = sunset - 0.5
0.379166666666667 = 0.879166666666667 - 0.5 (9:06 AM)

This is not the value I was looking for. I was looking for 8:34PM (0.856944444444444)

View 2 Replies View Related

If Statement Providing Incorrect Answer?

May 20, 2014

In cell K8 is the value (General) 800. In C8 is the value (Also general format) 768.

=IF(C8

View 4 Replies View Related

SUMIF - Trim And Concatenate 2 Sets Of 2 Columns Giving Answer In Another Column

Jun 22, 2008

I have two sets of two columns which contain numbers as text with trailing spaces and I want to concatenate column A and B and concatenate column F and G, and then compare them, and sumif value in column I if they are the same - giving the answer in the same row as the matching data in column A and B.. but in column J.

I’ve seen sum product and haven’t been able to get it to work at all. I have been adding the trim() function in around the column references to see if that would work but am failing…

A = 2000 text
B = 1234 text

F = 2000 trailing spaces, text
G = 1234 trailing spaces, text

I = 10,000

Answer in column J

I want 20001234 = 20001234 = 10,000 for the whole column.

I don't want to change the original data as its externally sourced and used for other links etc.. This would save a few hours a week if i ( more correctly, you ) could get this to work.

View 9 Replies View Related

Search Timestamp Value Giving Input With Date And Time Rounded Off Value Alone

Jul 29, 2013

I am a beginner to Excel macros. I am writing a macro to find the value based on the search criteria am giving

E.g. ( Record in table)

Column A
24/07/2013 15:04:05

Input am giving

24/07/2013 15:04 ( since am not sure about the milliseconds)

I need to find and fetch the Datas based on the input am giving

View 2 Replies View Related

Pie Chart Percentage Calculation Incorrect

Aug 21, 2013

This is so simple, yet Excel doesn't give the correct value. So, here you go, I only have 2 Cells and 2 Labels. One Label for one Number and the other Label for the other Number.

For the Pie Chart I chose Cells:

Cell B36 with the number $54288
Cell B39 with the number $166113

By simply viewing this one can see one of the Percentages should be around 33% and the other 66%. However, Excel gives it a Percentage of 25% and 75%.

How can I get the correct values?

View 2 Replies View Related

Make A Calculation(addition) And Use The Answer To Multiply Against Another Addition Calculation

Nov 19, 2008

make a calculation(addition) and use the answer to multiply against another addition calculation....

The sum of (Monday!A1:A4) multiplied by the sum of (Monday!B1:B4) plus (Tuesday!A1:A4) multiplied by the sum of (Tuesday!B1:B4) and so on.

View 2 Replies View Related

Date/Time Calculation For WeekEnds/After Business Hours

Jul 23, 2007

What calculation would I enter in a results cell if I wanted to find the delta between 2 times in date format that repersent just the business hours of 8am-5pm, therefore excluding after hours and weekends.

eg.

Date 1 Date 2 Result Time
23/07/07 8:00 24/07/07 14:55 15:55

So far I can't get the caluclation that will compensate for the after hours and week ends.

View 9 Replies View Related

Excel 2010 :: Average Calculation For Given Date And Time Range

Jul 9, 2014

Please find the attached 2010 version excel file <For a given date Time Range average .xlsx>.

I want to calculate the average value (Column C) for the given date (Column A) and given time range (Column B).

Values to be plotted in the color cells yellow and light pink / magenta.

Voting Results.xlsx‎

View 4 Replies View Related

Date Calculation Formula - Determine Longer Period Of Time

Aug 9, 2012

How to create a formula to determine the longer period of time between two date calculations and enter the longer period of time in the cell.

My Spreadsheet:
Cell M2: Birthdate (entered in cell as 11/1/2004)
Cell J2: Last date of service (entered in cell as 10/31/2011)
Cell G2: Calculation to enter the longer period of time between (M2 (year) + 21) and (J2 (year) + 7)

Example using information from above:
2004 + 21 = 2025
2011 + 7 = 2018
2025 is the result I want added to G2

If there is any way to include the month/year in G2 that would be ideal.

View 6 Replies View Related

Worksheetfunction.match Giving Run Time Error '1004'

Mar 4, 2008

I am trying to used match function in the code but I am getting the following error:

Run time error '1004'
Unable to get the match property of the worksheet-function class

Here is the

View 9 Replies View Related

Date Formats Incorrect When VBA Opens Workbook

Apr 29, 2008

I'm new to VBA so my i'm having alot of problems figuring out simple stuff.

Below is my script and when i run it, the dates turns out incorrect.

I noticed this only happens to dates that are before 13th of each month.

Example,

1st May 2008 ( 01/05/2008)

will turn up as

5th Jan 2008 ( 05/01/2008)

However when i manually open the file Todays trades.csv
The date looks just fine.

Is there some problem with using VBA to call up the file?

View 9 Replies View Related

Serial Number Date Displaying Incorrect Day?

Dec 16, 2008

I maintain a class register in Excel to monitor student attendance. The first row shows the date of the class in the form dd-mm.

I need to identify all dates which fall on a Monday and thought that if I custom formatted a new row as "dddd" and enter the formula =DAY(cell ref) into the cells of this new row it would achieve this- I could easily spot the Mondays for the period under review.

What I'm finding, however, is that the formula seems to incorrectly state that 16th September 2008 is a Monday whereas it's actually a Tuesday- utterly bizarre!

I can get a fix simply by modifying the =DAY() formula by adding 1 to my formula [ie =DAY(A1)+1] but am wondering is this a "so called known issue" with Excel or has anyone else come across it? I have never previously come across this and consider myself to be an above average competency level user of the application.

View 6 Replies View Related

Counting Amount Incorrect Within A Date Range

Jun 8, 2009

I would like some help from someone on this subject if possible. I am running a stats report in a workbook where each member of staff have their own running totals of how much work they do and how much of that work is incorrect (per week). I have worked out that if I use the following:-

=SUMPRODUCT(('Barry Brooks'!$A$1:$A$2000>=$B$95)*('Barry Brooks'!$A$1:$A$2000<=$C$95))

I get the total amount of work. To explain the above, it returns the amount of times a date appears between two dates i.e B95 is week commencing date and C95 is weekending; therefore giving the total amount of work in that period.

What I am struggling with is that I need a formula to look at the above date range and then look at another column that has either a ‘Y’ or ‘N’ (for yes or no) and for the formula to count how many N’s there are (thus how many in that given range there were)

It appears to me quite a small ask for Excel but I can’t seem to get it to work.

View 6 Replies View Related

VBA Importing Data From Access To Excel - Date Format Incorrect

Sep 8, 2008

I am using VBA to export an access query into excel, the query works fine in access but when importing the data into an excel spreadsheet, it doesn't display the date column headers in the correct format.

The problem I have is that the dates 1 to 12 are displayed the wrong way round eg:

In Access date column headers from query are:
09/01/2008, 11/01/2008, 12/01/2008, 14/01/2008, 15/01/2008 etc.

But when exporting to excel, the above dates are shown as:
01/09/2008, 01/11/2008, 01/12/2008, 14/01/2008, 15/01/2008 etc

It seems to be changing round the dd/mm when I export, but only upto 12 when the day is 13 or more it is displayed correctly.

Public Sub bttnDMA_Click()
'DMA Figures in Excel format
'Creating the Recordset
Dim cnn As ADODB.Connection
Set cnn = CurrentProject.Connection
Dim MyRecordset As New ADODB.Recordset
MyRecordset.ActiveConnection = cnn
Dim MySQL As String ....

View 9 Replies View Related

Time Calculation (Spanning Dates And Using Military Time)

Jul 15, 2014

I have 4 distinct columns.

Adm Date Adm Time Trans Date Trans Time
1/16/2014 937 1/16/2014 1045
1/1/2014 121 1/1/2014 121
1/14/2014 800 1/11/2014 735
1/30/2014 100 1/30/2014 205
1/13/2014 800 1/12/2014 1202

I would like to calculate the difference (# hours spanned from the dates shown). Unfortunately when we transfer the data the COLON is dropped from MILITARY TIME so I am having problems in the calculation. This is also made more difficult as some of the calculates span over two dates.

View 5 Replies View Related

Macro Or Userform For Extract Data From Multiple Workbooks By Giving Date Range

Apr 2, 2014

I jst need to console data from different workbooks to one worksheet. There are 30 workbooks & each workbook contains one worksheet name as Data. The work i am currently doing mentioned below step wise

1) Open workbook
2) Apply filter on whole data
3) Select dates from "J" Column (E.g 02/10/2014 to 02/20/2014)
4) Then Copy whole filtered data
5)Paste into New workbook
6) Open another worbook
7) repeate Step # 2,3
8)Then paste whole data in below the first data New Workbook (In which we have paste the first data below that i will paste this data)

These steps i have to do manually it takes almost 1hr daily After pasting all 30 workbooks data in one workbook i have to make pivot of it & sent it to my Manager. What i need

I jst want a excel macro that will ask me date range from which i have to pull data from all 30 workbooks.

Once i gave date range will jst click on button say extract or pull. It willl console whole 30 workbooks data from the given date range in a one worksheet.

View 13 Replies View Related

Userform Textbox Using VLookup Date Could Not Give Correct Answer (40850)

Nov 6, 2011

I created an UserForm that looks for Student Name his/her Conferenece Date through a VLookup.

The following is my code:

Private Sub cmdFind_Click()
With frmConference
.txtTranslator.Value = Application.WorksheetFunction.VLookup(txtStudentName.Value, Sheets("SPANISH").Range("A2:F113"), 6, 0)
.txtDate.Value = Application.WorksheetFunction.VLookup(txtStudentName.Value, Sheets("SPANISH").Range("A2:F113"), 5, 0)
.txtTime.Value = Application.WorksheetFunction.VLookup(txtStudentName.Value, Sheets("SPANISH").Range("A2:F113"), 4, 0)
End With
End Sub

The txtTranslator and txtTime works correctly, however txtDate give me a number '40850' not a Date?

How can I change this number for the actual Date?

View 9 Replies View Related

Calculation Of Time With Two Different Time Formats

Jan 30, 2007

Need a point in the right direction with this one! I want to calculate the difference between two time values, the problem is there two different formats as below:-

1) 520.00 - this is a number format

2) 500:00:00 - this is a time format HHH MM SS

What could I use to show I have a 20.00 hour difference???

View 2 Replies View Related

Date/Time Formula: Pick Up A Date With Time Entry On A Worksheet And Place It Into A TextBox On A UserForm

Jun 17, 2006

I am attempting to pick up a date with time entry on a worksheet and place it into a TextBox on a UserForm. Format on the sheet is mm/dd/yyyy h:mm AM/PM. The UserForm is placing the value as mm/dd/yyyy 12:00 AM. here is the

Private Sub UserForm_Initialize()
If Not Range("dDate").Value = "" Then
TextBox2.Value = Range("dDate").Value
TextBox2.Text = Format(DateValue(TextBox2.Text), "mm/dd/yy h:mm AM/PM")
Else
TextBox2.Value = ""
TextBox2.SetFocus
End If
End Sub


"dDate" is the named range where the date is sitting. The format is also set on the TextBox2 exit event. Can anyone see why only the date portion is being transfered with the default 12:00 AM for no time component of the value?

View 3 Replies View Related

Hh:mm:ss Time Calculation

Nov 5, 2008

i need to total a range of cells, however, these contain time values; hh:mm:ss. it shows me the total when all cells are highlighted. but =sum() doesn't work.

View 2 Replies View Related

Calculation On Time

Mar 1, 2009

I have been burning brain cells trying to figure this out.
I get these numbers from an online source and they come in like this:

A B C D E
1/1/0912:01AM02:40AM11:18AM07:55PM

The times do not come in as times...when I format the cell to time it doesnt change...that is my first problem.

What I would need to do to these times is: take B and C and find what time is in the middle of them and put that in a different column.

This mess will also need to be plotted on a chart with time by the minute for one day as the X axis. In my example I drew lines on the chart to show what I mean....the blue lines I dont want charted...I use those to find the time in the middle.

View 12 Replies View Related

Same Time Calculation

Feb 5, 2009

I am trying to get a total column that will give the total only when two particular devices are down at the same time. This total will be taken from a long list of downtime entries for different devices but I only want the total when two particular devices are down, for example

Devicedatedowntimedateuptimetotal time
102/01/0911:00:0002/01/0911:09:0000:09:00
202/01/0911:00:0002/01/0911:04:0000:04:00
202/01/0902/01/09
103/01/0903/01/09
303/01/0903/01/09
604/01/0904/01/09
204/01/0913:09:0004/01/0913:12:0000:03:00
104/01/0913:02:0004/01/0913:15:0000:13:00
505/02/0905/02/09
total 1/200:07:00

In the example I am just wanting to work out the total time when both device 1 and 2 were down at the same time, above the total would be 7 minutes because for 4 minutes on the 2/1/9 and 3 minutes on the 4/1/9 they were down at the same time.

View 9 Replies View Related

Time Calculation ...

Jun 4, 2009

Having been looking round this site for quite some time now and always finding what I needed I am now a registered member who needs your expertise.

I have a spreadsheet for which I need to calculate hours worked depending on a few criteria.

[data] ...

The criteria is that Sat/Eve is 8pm to 6am weekdays and midnight to midnight on a saturday. Sun is midnight to midnight on a sunday, BH is a bank holiday and basic is everthing else. What I want to know is it these columns can be populated automatically using formulas.

I would really appreciate it if someone out there is up to completing this challange, as I have to manually populate this at the moment and it can be 5000+ lines long (it takes hours). If i need to change the layout it's not a problem, whatever it takes to automate it has got to be worth the effort.

View 9 Replies View Related

Time Calculation

Apr 21, 2007

I have a time card sheet that I want to make automatically calculate the time I have worked. It is set up with four columns that can't be changed. The first column is "Time In(TI)", second column "Time Out(TO)", Third column "Time Taken For Lunch(TTFL)", and Finally "Hours Worked". I have no problem getting the formula to calculate the difference in "Time In" and "Time Out" but taking the 30 minutes out of that is causing a rift. If I put the 30 minutes in 00:30:00 format it will take it but it thinks it's 12:30:00 and it displays in 00:30:00 which I want it to display 30. Just to clarify, I am using =(TI-TO)-TTFL in the Hours Worked cell.

View 3 Replies View Related

Convert Imported Date / Time Data To Date / Time Format?

Jan 2, 2013

I have loaded a .csv file in which the first column contains date/times, e.g. 01/12/2012 00:00. How do I now tell Excel (2010) that this is in fact a date/time format? If I select one or more of the cells, click on the Number dialog box launcher and try to pick a suitable format tghe cells resolutely refuse to budge from being text (i.e. left-justified, still allows me to edit the 'seconds' component to a number > 60). Also which data type should I be using? The only one that appears to have a full date/time format listed is Custom (not Date or Time).

View 4 Replies View Related

How Do I Reduce Calculation Time

Sep 12, 2008

I am a big fan of huge files (30MB+) all interlinked with array formulas ...and lots of them. The problem is...one calculation take literally 5 hours. (I have one file I try to calculate since cca 4 hours now...it's at 63%)

I keep getting extra memory with no visible improvement on the processing time. Is there a trick out there that I can use? Something is clearly wrong.

I feel I will soon have to give up Excel, or my formulas, or my job ...

View 14 Replies View Related

Formatting With Time Calculation

Oct 15, 2009

I have a calculation whereby I use two variables which are 1. Man hours left in the week formatted as [hh] and 2. Amount of work left to do in the week formatted as 0" Man Hrs" I need to carry out a calc which says:- Man hours left in the week - Amount of work left to do in the week.

The answer should tell me if I have a deficit or surplus of hours which can then use for planning purposes. Unfortunately the problem I have is that I can't make the formatting the same for both unless someone knows of a workaround.

Man hours left in the week = 128. Man hours required to complete all work this week = 224. Therefore I need to say 128-224 = -96. However when I do this this an answer of 16 is returned.

View 5 Replies View Related







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