Re: Question for Windows/BeOS Developers.


Subject: Re: Question for Windows/BeOS Developers.
From: Aaron Lehmann (aaronl@vitelus.com)
Date: Wed Aug 23 2000 - 13:07:44 CDT


As a former Mac developer, I remember that TickCount() would return
the number of "ticks" (sixtieths of a second) since startup. This
COULD rap around but would require uptimes that are nonexistant on
MacOS. Everybody expects it to continually increase. I guess
indentification would have to be implemented differently on the MacOS.

On Wed, Aug 23, 2000 at 05:31:58PM +1000, Martin Sevior wrote:
>
> Hi Windows and BeOS types,
> I need to initialize the random number generator using srand so
> that we get different string of random numbers every time we invoke abi. I
> want to do this to make sure the List identification number is always
> unique.
>
> In Unix I can do
>
> srand( (UT_uint32) time())
>
> Which works great. time() returns the number seconds since 1970. Is there
> a similar function in windows? I just need a function that is guarenteed
> to give a different result on every call. Since time always increases this
> will always work :-)
>
> I knew I'd be able to work in a Physics use somewhere :-)
>
> Cheers
>
> Martin
>
>
>



This archive was generated by hypermail 2b25 : Wed Aug 23 2000 - 13:07:59 CDT