473,473 Members | 1,861 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

time.h

JLW
Why cannot I not access time.h? Here's the code:

#include <time.h>
long int seed = time(0); // Random Seed

I get the error:

error C2065: 'time' : undeclared identifier

Thanks,
JLW
Nov 17 '05 #1
5 3141
"JLW" <as***@someplace.com> wrote in message
news:ut**************@TK2MSFTNGP12.phx.gbl...
Why cannot I not access time.h? Here's the code:

#include <time.h>
long int seed = time(0); // Random Seed

I get the error:

error C2065: 'time' : undeclared identifier


Is that it in its entirety? Is there are namespace line nearby?

Regards,
Will
Nov 17 '05 #2
JLW
Pretty much, but, in investigation, time.h does not exist on either of my
devel systems. I'm using VC++ 7, and it's unmanaged.
I talked to one of our other programmers, and he's had the dame problem for
2 years, no time.h, and nothing but problems.

Thanks,
JLW
"William DePalo [MVP VC++]" <wi***********@mvps.org> wrote in message
news:uw**************@TK2MSFTNGP10.phx.gbl...
"JLW" <as***@someplace.com> wrote in message
news:ut**************@TK2MSFTNGP12.phx.gbl...
Why cannot I not access time.h? Here's the code:

#include <time.h>
long int seed = time(0); // Random Seed

I get the error:

error C2065: 'time' : undeclared identifier


Is that it in its entirety? Is there are namespace line nearby?

Regards,
Will

Nov 17 '05 #3
"JLW" <as***@someplace.com> wrote in message
news:uv**************@tk2msftngp13.phx.gbl...
Pretty much, but, in investigation, time.h does not exist on either of my
devel systems. I'm using VC++ 7, and it's unmanaged.
I talked to one of our other programmers, and he's had the dame problem for 2 years, no time.h, and nothing but problems.


Hmm. Does your staff use machines derived from a common base-level system?

On this VS.Net 2003 system, "dir time.h" reports this:

05/31/2002 02:28 AM 5,628 time.h

My guess is that it is a bad setup. Do you have a directory named something
like

"C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\include"

Does it not include about 150 headers?

Regards,
Will
Nov 17 '05 #4
JLW
Now this is strange, it didn't show up under a windows search, but in going
to the directory by hand, things are starting to fall into place. WTF is
going on with that?

Okay, so that problem solved, now it's time to move onto other challenges.

Thanks again,
JLW
"William DePalo [MVP VC++]" <wi***********@mvps.org> wrote in message
news:OL**************@tk2msftngp13.phx.gbl...
"JLW" <as***@someplace.com> wrote in message
news:uv**************@tk2msftngp13.phx.gbl...
Pretty much, but, in investigation, time.h does not exist on either of my devel systems. I'm using VC++ 7, and it's unmanaged.
I talked to one of our other programmers, and he's had the dame problem for
2 years, no time.h, and nothing but problems.


Hmm. Does your staff use machines derived from a common base-level system?

On this VS.Net 2003 system, "dir time.h" reports this:

05/31/2002 02:28 AM 5,628 time.h

My guess is that it is a bad setup. Do you have a directory named

something like

"C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\include"

Does it not include about 150 headers?

Regards,
Will

Nov 17 '05 #5
JLW
I've got this problem licked, but now have a new one, and I'll start a new
thread....

Thanks,
JLW

"JLW" <as***@someplace.com> wrote in message
news:OE**************@TK2MSFTNGP09.phx.gbl...
Now this is strange, it didn't show up under a windows search, but in going to the directory by hand, things are starting to fall into place. WTF is
going on with that?

Okay, so that problem solved, now it's time to move onto other challenges.

Thanks again,
JLW
"William DePalo [MVP VC++]" <wi***********@mvps.org> wrote in message
news:OL**************@tk2msftngp13.phx.gbl...
"JLW" <as***@someplace.com> wrote in message
news:uv**************@tk2msftngp13.phx.gbl...
Pretty much, but, in investigation, time.h does not exist on either of my devel systems. I'm using VC++ 7, and it's unmanaged.
I talked to one of our other programmers, and he's had the dame
problem for
2 years, no time.h, and nothing but problems.


Hmm. Does your staff use machines derived from a common base-level system?
On this VS.Net 2003 system, "dir time.h" reports this:

05/31/2002 02:28 AM 5,628 time.h

My guess is that it is a bad setup. Do you have a directory named

something
like

"C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\include"

Does it not include about 150 headers?

Regards,
Will


Nov 17 '05 #6

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

Similar topics

3
by: Szabolcs Nagy | last post by:
I have to measure the time of a while loop, but with time.clock i always get 0.0s, although python manual sais: "this is the function to use for benchmarking Python or timing algorithms" So i...
6
by: cournape | last post by:
Hi there, I have some scientific application written in python. There is a good deal of list processing, but also some "simple" computation such as basic linear algebra involved. I would like to...
6
by: Rebecca Smith | last post by:
Today’s question involves two time text boxes each set to a different time zone. Initially txtCurrentTime will be set to Pacific Time or system time. This will change with system time as we travel...
3
by: luscus | last post by:
Thanks for all the responses on my first question. Unfortunately the answers I was given were too complicated for my small brain , and neophite condition to understand. So if you could talk down to...
0
by: Edward Diener | last post by:
In Borland's VCL it was possible to divide a component into design time and run time DLLs. The design time DLL would only be necessary when the programmer was setting a component's properties or...
1
by: Alfonso Morra | last post by:
Hi I'm compiling some code and need to generate some random numbers. To save time, I decided to use the srand, rand and time functions. My code worked (atleast built fine) until I added time.h,...
3
by: cj | last post by:
If I want to check to see if it's after "11:36 pm" what would I write? I'm sure it's easy but I'm getting tired of having to work with dates and times. Sometimes I just want time or date. And...
6
by: Luvin lunch | last post by:
Hi, I'm new to access and am very wary of dates as I have limited experience in their manipulation and I know if they're not done properly things can turn ugly quickly. I would like to use a...
1
by: davelist | last post by:
I'm guessing there is an easy way to do this but I keep going around in circles in the documentation. I have a time stamp that looks like this (corresponding to UTC time): start_time =...
2
by: Roseanne | last post by:
We are experiencing very slow response time in our web app. We run IIS 6 - windows 2003. I ran iisstate. Here's what I got. Any ideas?? Opened log file 'F:\iisstate\output\IISState-812.log'...
0
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,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
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,...
0
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...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
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 ...
0
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.