The following link goes to an excellent article which describes how to create a Team Foundation Server automated build using a batch file that can be leveraged for any project.  The idea is to use this batch file and then schedule it using the Scheduled Tasks capability in Windows.

http://blogs.msdn.com/abhinaba/archive/2005/11/21/495179.aspx