Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Visual Basic > VB 6 Visual Basic 6 > Beginning VB 6
| Search | Today's Posts | Mark Forums Read
Beginning VB 6 For coders who are new to Visual Basic, working in VB version 6 (not .NET).
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Beginning VB 6 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
  #1 (permalink)  
Old August 11th, 2008, 01:25 AM
Registered User
 
Join Date: Jun 2008
Location: Valenzuela, Metro Manila, Philippines.
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to lechalas
Default Time Shift time in minus time out

Hi all,

Please help us to solve this problem..Im working in the time and attendance system then i encounter error in computing ng total hours..Iam using datediff, " BEFORE_OT = DateDiff("n", #6:02:00 AM#, #12:20:00 PM#)" and result is 8 hour...so my question is how can i include the minutes in the computation using date diff??in my computation the right result is 6.18 hours..please advise,thanks
  #2 (permalink)  
Old August 11th, 2008, 01:56 PM
Friend of Wrox
 
Join Date: Nov 2004
Location: Port Orchard, WA, USA.
Posts: 1,621
Thanks: 1
Thanked 3 Times in 3 Posts
Default

Code:
CDate(#12:20:00 PM# - #6:02:00 AM#) = 6:18:00 AM
You will need to take care regarding crossing midnight.


Similar Threads
Thread Thread Starter Forum Replies Last Post
synchronizing pocket pc time with desktop time bobbyrayudu83 C# 1 April 2nd, 2011 04:28 AM
Time shift logic ADVANCED-plz help zrtv Beginning VB 6 5 September 17th, 2007 02:08 AM
Time Shift Logic !!! dpkbahuguna Beginning VB 6 3 August 31st, 2007 11:56 AM
time zone & day light time rajn ASP.NET 1.0 and 1.1 Professional 0 August 7th, 2007 05:02 PM
Using xs:time to generate time in desired format krayan001 XSLT 0 June 27th, 2005 04:28 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.