Log file by current date and time

Hi,Can anybody help me to create log file by current date and time.log? Please help me.
[108 byte] By [karimullaa] at [2007-10-3 10:23:30]
# 1

1) Open a notepad.

2) .LOG at the first line in a notepad.

3) Save with any name.

4) Whenever you open the file, It will put the current date and time first and then put your logs after that.

This is true. This is general. Not in java. Give a try manual try first. And give a try with Java.

harishotya at 2007-7-15 5:45:15 > top of Java-index,Java Essentials,Java Programming...
# 2
try this http://javaalmanac.com/egs/java.util.logging/LogFile.html
SvHa at 2007-7-15 5:45:15 > top of Java-index,Java Essentials,Java Programming...
# 3
Thank u for ur suggestion but i want the file name of log file by current date and timeEx:211120006 12:41PM.log
karimullaa at 2007-7-15 5:45:15 > top of Java-index,Java Essentials,Java Programming...
# 4
name it when its being created?
SvHa at 2007-7-15 5:45:15 > top of Java-index,Java Essentials,Java Programming...
# 5
Use Date class to extract to current date and time to a String.Then, massage the String using String/StringBuffer classes to suit your particular format and append .log at the end. Then use FileWriter class to open a new file by the name of the above String. Chris
ChrisLesliea at 2007-7-15 5:45:15 > top of Java-index,Java Essentials,Java Programming...
# 6

even i want to create a log file, iplz someone help me also. i tried .LOG, but its getting replaced every time a person logs in. i m making a project which contains a login file and i want to make a log file which can keep record of the person who logs in every time with date and time. the file should contain record of atleast one month i.e all the logins done in 1 month should be shown by that file.

plz help me out.

thanks in advance.

mansi_b85a at 2007-7-15 5:45:15 > top of Java-index,Java Essentials,Java Programming...