-1

I want to write a file in the Absolute Path with date and Time. for example C:\Users\PC\programme\NewDATA_15/06/2016 00.35.57.txt. NewDATA_15/06/2016 00.35.57.txt is a file name.

SHam
  • 33
  • 1
  • 1
  • 4
  • 1
    Welcome to StackOverflow. Please read our [ask] page for hints on how to improve your question. Great question tend to provide quicker, better answers from the community – blurfus Jun 14 '16 at 19:08
  • If this is for Windows, "/" is illegal. And: http://stackoverflow.com/a/5683761/669576 – 001 Jun 14 '16 at 19:17

1 Answers1

0

Instead of \\ and / use File.separator for all File operations.

and for the date part look at the link that Johnny Mopp has already commented: Convert java.util.Date to String

Community
  • 1
  • 1
Marcel
  • 1,509
  • 1
  • 17
  • 39
  • I am just guessing that this is your problem cause your question has no Information, hope that helps – Marcel Jun 14 '16 at 20:01