473,657 Members | 2,484 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Getdate and gettime

Hi!

I look for a function that work with linux to get the date and the time.
Can somebody help me?

Thanks

Yann
Nov 13 '05 #1
3 12323
On Sun, 02 Nov 2003 14:42:04 -0500, in comp.lang.c , "Yann Laviolette"
<ya************ *@gnome.org> wrote:
Hi!

I look for a function that work with linux to get the date and the time.
Can somebody help me?


Yann
usenet is not IM. You need to wait for answers, not post the same
question again 20 mins later. Sometimes you need to wait for days.
Remember usenet is also global, and not everyone is awake when you
post.

--
Mark McIntyre
CLC FAQ <http://www.eskimo.com/~scs/C-faq/top.html>
CLC readme: <http://www.angelfire.c om/ms3/bchambless0/welcome_to_clc. html>
----== Posted via Newsfeed.Com - Unlimited-Uncensored-Secure Usenet News==----
http://www.newsfeed.com The #1 Newsgroup Service in the World! >100,000 Newsgroups
---= 19 East/West-Coast Specialized Servers - Total Privacy via Encryption =---
Nov 13 '05 #2
Le Sun, 02 Nov 2003 21:42:02 +0000, Mark McIntyre a écrit*:
r. Sometimes you need to wait for days.
Remember usenet is also global, and not everyone is awake when you
post.


Ok Mark, But I was thinking that the message wasn't sent because I have
little problem with my Internet connection.

That's why a resend my message!

Have a good day!

Yann
Nov 13 '05 #3

"Yann Laviolette" <ya************ *@gnome.org> wrote in message
news:pa******** *************** *****@gnome.org ...
Hi!

I look for a function that work with linux to get the date and the time.
Can somebody help me?


Look up the functions in the standard header <time.h>

-Mike
Nov 13 '05 #4

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

Similar topics

2
8736
by: Konstantin Zakharenko | last post by:
Hello, Our QA team have running a lot of test scripts (for automated regression testing), they run them on the different databases (Oracle/MS SQL). Several of those tests are dependent on the current date/time. In order to be able to use them efficiently, we changed the current date/time on the QA database server to a specific date/time before starting the scripts, so we are sure the test scripts always run in the same environment.
3
1479
by: Xiangliang Meng | last post by:
Hi, all class Clock { Clock() { Time_m = 0;} void setTime(unsigned int time = 0) { Time_m = time; } unsigned int getTime() const
10
2041
by: Bill Edwards | last post by:
I'm trying to produce an array of working days but want to force Saturday and Sunday to return the date of the previous Friday, e.g. Sunday 9/12/04 should return Friday 9/10/04 and similarly Saturday 9/11/04 should return Friday 9/10/04. I've tried getdate()-1 and getdate()-2 respectively but am getting stack overflow errors. Am I doing anything wrong, or is this just not possible?
8
6103
by: Russ Chinoy | last post by:
Has anyone ever noticed that getTime() returns the same value for both today (5/31/2005) and tomorrow (6/1/2005)? You can quickly see it with this page: <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <title>Untitled Document</title> <script>
3
6518
by: Yann Laviolette | last post by:
Hi! I look for a function like the Windows function getdate(&d); and gettime(&t); to have the date and the time. Also I look for a function like spawnl to call another program. These function should work with Linux. Can somebody help me? Thanks a lot!
2
7295
by: Shane Saunders | last post by:
I trying to make a sub that works like Javascripts .getTime method. It work ok, but it does not should the time in it. The last numbers should be the time, but they are all zeros. Can anyone help me on this. here is the code i used. From reading i also seen that the getTime time starts on 01/01/1970 12am. I need to have this in Millsecond. VB.net Code: Dim days As Long Dim date1970 As Date = "#1/1/1970 12:00:00 AM#" Dim datenow As Date...
4
6579
by: jim_geissman | last post by:
According to MS, GetLocalTime() (in C++) is only accurate to approx a second, even though it reports milliseconds, and calling it twice and computing the interval can on occasion lead to a negative interval. Is T-SQL's GetDate() more accurate than that, or at least non-decreasing? Thanks,
6
6379
by: Matik | last post by:
Hi, I have a funny situation. Within: MSSQL 2000 SP3, everything below described is running on same PC. there is a program running, which sends information to two other programs. This information is a timestamp of the program in datetime format, which has it's own clock.
6
2436
by: FFMG | last post by:
Hi, My timezone is GMT +2 So when I do a $date = getdate( 0 ); I get: $date = {
12
14721
by: anj2k5 | last post by:
Hello , I want to create a function in C#.net which is equivalent to gettime(milliseconds since midnight 1st January, 1970 ) function in javascript. Actually i need to calculate unique value in c#.net as given in following javascript //javascript var unique = d.getTime() + '' + Math.floor(1000 * Math.random()); I used following code in c#
0
8421
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8844
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8742
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8518
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7354
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6177
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4330
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2743
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1971
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.