[Solved] Create a function that takes string object and returns Date object in dd-MM-yyyy format [duplicate]
[ad_1] I have done lot of research over web, but I got solution from one Expert. Date getDateFrmString(String dDate) { java.sql.Date dDate = new java.sql.Date(new SimpleDateFormat(“yyyy-MM-dd”).parse(sDate).getTime()); return dDate; } this is what I want. [ad_2] solved Create a function that takes string object and returns Date object in dd-MM-yyyy format [duplicate]