473,378 Members | 1,468 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

form usage time

Hi All,

I have a problem about my form. My aim is to get total time spent on, before saving the record to the database on a form. I used the time function when the form loads and save it to the field "dinleme_basla". I want the duration time on the form until the user clicks "save record" button. And save that record to the field called "dinleme_bitis".

Can anyone help me?
Nov 27 '06 #1
6 1358
Try this to display the time spent (note you'll need to change the format of the fields to short time):

Private Sub Form_Load()
[dinleme_basla].SetFocus
[dinleme_basla].Text = Now()
End Sub

Private Sub SaveRecord_Click()
TimeSpent = Now() - [dinleme_basla]
DoCmd.Close
End Sub

Cheers,
Cz
Nov 27 '06 #2
Try this to display the time spent (note you'll need to change the format of the fields to short time):

Private Sub Form_Load()
[dinleme_basla].SetFocus
[dinleme_basla].Text = Now()
End Sub

Private Sub SaveRecord_Click()
TimeSpent = Now() - [dinleme_basla]
DoCmd.Close
End Sub

Cheers,
Cz
it didn't worked
i must use long time as well
Nov 27 '06 #3
MMcCarthy
14,534 Expert Mod 8TB
Try this ...

Expand|Select|Wrap|Line Numbers
  1.  
  2. Private Sub Form_Current() 
  3.    Me.[dinleme_basla] = Now()
  4. End Sub
  5.  
Expand|Select|Wrap|Line Numbers
  1.  
  2. Private Sub SaveRecord_Click()
  3.    TimeSpent = Format(Now() - [dinleme_basla],"Long Time")
  4.    DoCmd.Close
  5. End Sub
  6.  
Nov 27 '06 #4
PEB
1,418 Expert 1GB
Try this ...

Expand|Select|Wrap|Line Numbers
  1.  
  2. Private Sub Form_Current() 
  3.    Me.[dinleme_basla] = Now()
  4. End Sub
  5.  
Expand|Select|Wrap|Line Numbers
  1.  
  2. Private Sub SaveRecord_Click()
  3.    TimeSpent = Format(Now() - [dinleme_basla],"Long Time")
  4.    DoCmd.Close
  5. End Sub
  6.  
Mary he double posted!

He has 2 threads running simultannelly!

How can explain that double posting isn't good practice!
Nov 27 '06 #5
MMcCarthy
14,534 Expert Mod 8TB
Mary he double posted!

He has 2 threads running simultannelly!

How can explain that double posting isn't good practice!
barisbasar,

Please note that you have posted your question twice. This will confuse and may even annoy the experts. It also makes it difficult for others searching for the answer to their question in your posts.

Please do not do this. If your post doesn't get answered, which doesn't happen very often, then just post a reply to move it up the list and it will be attended to.

Mary
Nov 27 '06 #6
NeoPa
32,556 Expert Mod 16PB
The other thread is (users usage time on form).
FYI the reasons why it is requested that you do not double post are in (Please do Not Double Post). Although we appreciate that not everyone gets to see all threads, so no censure is implied here.
I will lock this thread now. Further correspondence can be carried out via the other thread.
Nov 27 '06 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Randell D. | last post by:
Folks, I am working on a contact db using PHP and MySQL. My results so far outputs a slimed down version of records to the browser. I would like to implement a method whereby the user can...
26
by: Bruno Jouhier [MVP] | last post by:
I'm currently experiencing a strange phenomenon: At my Office, Visual Studio takes a very long time to compile our solution (more than 1 minute for the first project). At home, Visual Studio...
4
by: RH | last post by:
Hi, I am building a windows application that has a feature that retrieves a set of records when a button is clicked. When the records are being retrieved I experience a complete system...
3
by: Leo J. Hart IV | last post by:
OK, here's another question for the experts: I am building a multi-step (3 steps actually) form using a panel for each step and hiding/displaying the appropriate panel/panels depending on which...
3
by: Sirisha | last post by:
I am using the following code to get the CPU usage PerformanceCounter myCounter; myCounter = new PerformanceCounter(); myCounter.CategoryName = "Processor"; myCounter.CounterName = "%...
11
by: Alex | last post by:
Hello all, I have a main form(say "form1") .i want to display another form(say "form2") on occuring of an event (say a button click) and want to hide it after some time so that it will again...
3
by: chrispy102 | last post by:
Hi all, I have an MDI app developed using vis studio 2005. The problem I have is that evey time I close a Child form and open another, the CPU PF Usage increments slighty. This happens every time...
0
by: tony_in_da_uk | last post by:
*** I posted this on comp.lang.c++.moderated a couple days ago, and got a near-flippant response from someone who clearly didn't take the time to consider the import. I replied, and it's still not...
11
by: dhtml | last post by:
(originally mis-posted on m.p.s.jscript...) I've just closed all windows in Firefox and its using 244MB of memory. I have no idea why. I had GMail open, a page from unicode, the CLJ FAQ. ...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.