![]() |
Excel VBA: Subtracting TIMES
If cell A1 = "5:00 PM" and cell A2 = "5:15 PM", what should the formul for A3 be if I want to display the difference - i.e. 15 minutes? Thanks -- Laze ----------------------------------------------------------------------- Lazer's Profile: http://www.excelforum.com/member.php...nfo&userid=750 View this thread: http://www.excelforum.com/showthread.php?threadid=27701 |
Excel VBA: Subtracting TIMES
Try the following formula:
=(A2-A1)*60*24 -- Cordially, Chip Pearson Microsoft MVP - Excel Pearson Software Consulting, LLC www.cpearson.com "Lazer" wrote in message ... If cell A1 = "5:00 PM" and cell A2 = "5:15 PM", what should the formula for A3 be if I want to display the difference - i.e. 15 minutes? Thanks! -- Lazer ------------------------------------------------------------------------ Lazer's Profile: http://www.excelforum.com/member.php...fo&userid=7500 View this thread: http://www.excelforum.com/showthread...hreadid=277018 |
Excel VBA: Subtracting TIMES
=A2-A1
format as hh:mm:ss or =(A2-A1)*24*60 and format as general if you want a number (rather than a time value) like 15 as the answer. -- Regards, Tom Ogilvy "Lazer" wrote in message ... If cell A1 = "5:00 PM" and cell A2 = "5:15 PM", what should the formula for A3 be if I want to display the difference - i.e. 15 minutes? Thanks! -- Lazer ------------------------------------------------------------------------ Lazer's Profile: http://www.excelforum.com/member.php...fo&userid=7500 View this thread: http://www.excelforum.com/showthread...hreadid=277018 |
All times are GMT +1. The time now is 05:53 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com