Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]() After you produce the Updated sheet, Format column C, W, X, Y and Z as [hh]:mm:ss Format column S, T, U and V as number, no decimal places. In S2 put the formula =IF($B2="","",IF(N2=0,S1,IF($C2<$C1,1,IF(S1="",1, S1+1)))) and formula drag that acros T2, U2 and V2 In W2 put the formula =IF($B2="","",IF(N2=0,W1,IF($C2<$C1,N2,IF(W1="",N 2,W1+N2)))) and formula drag that across X2, Y2 and Z2 Select (highlight) S2-Z2 and formula drag the 8 column formula to the end of your data. This gives you the Count of items per 15 minute period, and the Sum per 15 minute period, you need to divide W2 by S2, X2 by T2, Y2 by U2 and Z2 by V2 etc to obtain the average. Hope this helps -- Bryan Hessey Wrote: Adam, The attached should produce the required sheet as per the code supplied by Toppers, and the column K fix. Simply Tools, Macros, Macro and Run the macro. This will populate the new worksheet. To do this to other worksheets you need to copy the macro and amend the names of the sheets on lines 5 and 6. To see the code you can: 1. press Alt/F11 or 2. rightmouse the sheet-name-tab and select View Code or 3. Tools, Macros, Macro, Edit Select and copy all of the code, and 'view code' on the next sheet and Paste the code. Insert a new sheet and rename it to 'Updated ~~~ etc' then within the just pasted locate and amend the two sheetnames to be the sheets you are now using. Then Tools, Macros, Macro and select and run the new copy. This should re-produce the the workbook that Toppers sent you, and you can then do the remaining workbooks. Am still testing how to average over 15 min periods. also, you need to format column C to [hh]:mm:ss Bryan -- Bryan Hessey ------------------------------------------------------------------------ Bryan Hessey's Profile: http://www.excelforum.com/member.php...o&userid=21059 View this thread: http://www.excelforum.com/showthread...hreadid=530452 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Need to Improve Code Copying/Pasting Between Workbooks | Excel Discussion (Misc queries) | |||
IF/AND/OR/DATEIF Issue...sorry...long post... | Excel Worksheet Functions | |||
creating a bar graph | Excel Discussion (Misc queries) | |||
sorting cells according to all cells in column A | Excel Worksheet Functions | |||
Adding a KeyID column for sorting | New Users to Excel |