Please do not double post. This is not a free software store. It is a learning forum. See the C time functions. Post back (including your code) if you have problems. Read the "Before you make a query" thread.