reading dates from file - how to format
Hello again,
I cannot understand how to format dates in interpreted Java. I have the following in my script:-
File inputFile = new File( "Datefile.txt" );
import java.text.SimpleDateFormat;
FileReader in = new FileReader( inputFile );
BufferedReader buffRead = new BufferedReader( in );
while( ( searchTerm = buffRead.readLine() )!=null)
{
SimpleDateFormat formatter = new SimpleDateFormat( "dd/MM/yyyy" );
String formattedDate = formatter.format( searchTerm );
session.setVariable( "ActDate", formattedDate );
session.log( session.getVariable( "ActDate" ) );
}
in.close();
buffRead.close();
Any help appreciated as Im not a coder of Java....
thanks, Kerri
reading dates from file - how to format
Hi,
Are you trying to change a date from one format to another? If so, this method may be more helpful to you: http://community.screen-scraper.com/API/reformatDate.
Kind regards,
Todd Wilsn