Are there vb functions to compute/convert time values?
I'm thinking that, as the script goes along, it takes a time() reading at the start of the record processing, and one at the end. Subtract the beginning from the ending to get record processing elapsed time and add that to a running total of elapsed time. Divide that by the current record number to get average per-record process time, and use that value times total records to get estimated process time for the data set. Then use that value to get the estimated stop time (from script start time, or first record start time). Then once you have that, you can display the amount of time to that value from the current time. Whew. Thank you, Mitch Lawrence Lead Applications Analyst Technical Support - NPR/Automation CHRISTUS Information Management *: [email protected] <mailto:[email protected]> Send a "thank you <http://intranet.christushealth.org/spiritBuck/Default.asp> " to someone! ________________________________ From: [email protected] [mailto:[email protected]] Sent: Tuesday, February 17, 2009 11:01 AM To: [email protected] Subject: [talkbws] RE: Computing estimated completion time Ha ha.... My approach would be have a timer that once started ticks at .25 second intervals, adding the .25 interval to a var for storage. When the D.Next_ command is performed you could calculate the value in var multiplied by the number of records left (total - already processed) to give you the number of seconds then if you want minutes divide your seconds by 60 and again divide by 60 hours. Obviously, you would then update the message on your form... Brian Stevenson | Systems Administrator University Health System <http://www.universityhealthsystem.com/> | Business Information Services 355-2 Spencer Lane | San Antonio, TX 78229 Office | (210) 358 - 9282 Pager | (210) 203 - 9851 From: [email protected] [mailto:[email protected]] Sent: Tuesday, February 17, 2009 10:52 AM To: [email protected] Subject: [talkbws] RE: Computing estimated completion time Mitch Since it's you I can't resist this one! Why not take the Windows Update approach and randomly generate numbers until your process is done?? David Gibbs Analyst, Laboratory Information Systems Fraser Health, Burnaby, BC ________________________________ From: [email protected] [mailto:[email protected]] Sent: February 17, 2009 8:42 AM To: [email protected] Subject: [talkbws] Computing estimated completion time Hello all, I've currently got a progress bar that I use for my data entry scripts and I wanted to figure out a way to also display an "estimated" completion time that is updated based on the time it takes to process a record. Any ideas how I could do something of this nature? My process is that I count the total records in the datasource, and then do an update of the progress bar after each D.Next_: As far as estimating time, what I do now is sit there and watch a record be processed, start to finish, counting in my head "one-one thousand, two-one thousand, three-one thousand", etc until the record finishes. I know it's not totally accurate, but it gives me an idea how many seconds each record takes. I take that total, multiply by the total records, divide by 60 twice to get hours in decimals and then subtract whole hours, multiply by 60 to get minutes. I can then add the hours and minutes to the script start time and get an estimated time of completion. For the purpose of the status bar, I would just be interested in some time of "estimated completion in xx:xx minutes" type of update on each record processed. I'm stuck on what formula to use though. Thoughts? Thank you, Mitch Lawrence Lead Applications Analyst Technical Support - NPR/Automation CHRISTUS Information Management *: [email protected] <mailto:[email protected]> Send a "thank you <http://intranet.christushealth.org/spiritBuck/Default.asp> " to someone! --- --- To post a message to this list, send mail to: [email protected] You are currently subscribed as: [email protected] Unsubscribe in the customer center on our website: http://www.bostonworkstation.com/customer_center/virtual_user_group_talk .aspx --- To post a message to this list, send mail to: [email protected] You are currently subscribed as: [email protected] Unsubscribe in the customer center on our website: http://www.bostonworkstation.com/customer_center/virtual_user_group_talk .aspx --- To post a message to this list, send mail to: [email protected] You are currently subscribed as: [email protected] Unsubscribe in the customer center on our website: http://www.bostonworkstation.com/customer_center/virtual_user_group_talk .aspx --- To post a message to this list, send mail to: [email protected] You are currently subscribed as: [email protected] Unsubscribe in the customer center on our website: http://www.bostonworkstation.com/customer_center/virtual_user_group_talk .aspx ________________________________ CONFIDENTIALITY NOTICE: This communication is intended only for the use of the individual or entity to which it is addressed and may contain information that is privileged, confidential, and exempt from disclosure under applicable law. If you are not the intended recipient, you are notified that any use, dissemination, forwarding, distribution, or copying of the communication is strictly prohibited. Please notify the sender immediately by e-mail if you have received this by mistake and delete this e-mail from your system. (University Health System) --- To post a message to this list, send mail to: [email protected] You are currently subscribed as: [email protected] Unsubscribe in the customer center on our website: http://www.bostonworkstation.com/customer_center/virtual_user_group_talk .aspx --- To post a message to this list, send mail to: [email protected] You are currently subscribed as: [email protected] Unsubscribe in the customer center on our website: http://www.bostonworkstation.com/customer_center/virtual_user_group_talk .aspx
<<image001.jpg>>
<<image002.gif>>
