Solved

lap time

Posted on 1998-11-21
4
276 Views
Last Modified: 2010-04-01
I wanted to know how can u find the lap time that is given the elapsed time how can u find the lap time.l
for ex if u have an elapsed time button and a start button, a stop button,and a lap time button then when u click on the
start button then this starts the counter and shows the time
on the elapsed time now if u click on the lap time button this should freeze the display and when u click it again it should show the elapsed time as the time that has lasped +time that was previosly tehre.how do u do this in motif?????
any suggestions?????
0
Comment
Question by:ragini112198
  • 2
  • 2
4 Comments
 
LVL 5

Expert Comment

by:scrapdog
ID: 1178406
The lap time is just a "snapshot" of the elapsed time.

Make a variable to store the lap time, and a flag to indicate whether elapsed time or lap time is display (true for lap time, false for elapsed time).

When the lap time button is pressed, move the current elapsed time to lap time.  Then toggle the flag.

In the procedure that displays the time, check the flag.  If it is true, display the value in the lap time variable.  If it is false, display the value in elapsed time.
0
 

Author Comment

by:ragini112198
ID: 1178407
Thanks a lot for the person whoever it is.i needed it for getting my assignment done for monday and i just got it in time.Thanks  a lot.
0
 
LVL 5

Accepted Solution

by:
scrapdog earned 100 total points
ID: 1178408
Is this enough information?
0
 

Author Comment

by:ragini112198
ID: 1178409
Thanks a lot scrapdog for ur help.it was really needed but i got to still work on it and if i have problems with it i will post it tomorrow.please do help.thanks a lot for ur help
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Quicksort a dynamic deque 33 79
Problem with SqlConnection 4 184
How to measure current at integrated circuit (IC) power pin using Current Probe ? 6 57
Finding Divisors 5 39
Templates For Beginners Or How To Encourage The Compiler To Work For You Introduction This tutorial is targeted at the reader who is, perhaps, familiar with the basics of C++ but would prefer a little slower introduction to the more ad…
Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question