Here is what I came up with to print (without saving to a
String) the current date/time.
You need to import java.util.Date (to get the current date) and java.text.SimpleDateFormat (to define the display format).
System.out.println(new SimpleDateFormat("yyyyMMddHHmmss").format(new Date()));
Hope that helps.
Ross