newDate =(newDaysAdded+"/"+month+"/"+year);
SimpleDateFormat date = new SimpleDateFormat("dd/MM/yyyy");
try {
Date newDateOne = date.parse(newDate);
When I try:
view.writeToScreen(newDateOne);
I get the error:
Incompatible types: Date cannot be converted to String.
Here is the writeToScreen method:
void writeToScreen(String s);
However from there I can't turn into a string, I have tried:
String test = Date.toString(newDateOne);
Can anyone help?
No comments:
Post a Comment