Skip to main content

This error is coming as system is not able to understand Test123 while parsing into date.

The format of the String depends on the local date format, like mm/dd/yyyy. If the parameter is not of this format, date.parse will throw an error.

E.g.:

r.Plan_Date__c = date.parse('12/27/2015');

You can also use date.valueOf(strDate) to parse string of format yyyy-MM-dd HH:mm:ss in the local time zone.

Please use this linkread about more date properties to read about more date properties.

This error is coming as system is not able to understand Test123 while parsing into date.

The format of the String depends on the local date format, like mm/dd/yyyy. If the parameter is not of this format, date.parse will throw error.

E.g.:

r.Plan_Date__c = date.parse('12/27/2015');

You can also use date.valueOf(strDate) to parse string of format yyyy-MM-dd HH:mm:ss in the local time zone.

Please use this link to read about more date properties.

This error is coming as system is not able to understand Test123 while parsing into date.

The format of the String depends on the local date format, like mm/dd/yyyy. If the parameter is not of this format, date.parse will throw an error.

E.g.:

r.Plan_Date__c = date.parse('12/27/2015');

You can also use date.valueOf(strDate) to parse string of format yyyy-MM-dd HH:mm:ss in the local time zone.

Please read about more date properties.

THisThis error is coming as system is not able to understand 'Test123'Test123 while parsing into date.

The format of the String depends on the local date format, like 'mm/dd/yyyy' mm/dd/yyyy. If the parameter is not of this format  , date.parsedate.parse will throw error.

Eg: rE.Plan_Date__c = dateg.parse('12/27/2015');:

r.Plan_Date__c = date.parse('12/27/2015');

You can also use date.valueOf(strDate)date.valueOf(strDate) to parse string of format “yyyy-MM-dd HH:mm:ss”yyyy-MM-dd HH:mm:ss in the local time zone.

Please use this linkthis link to read about more date properties. https://developer.salesforce.com/docs/atlas.en-us.198.0.apexcode.meta/apexcode/apex_methods_system_date.htm#apex_System_Date_parse

THis error is coming as system is not able to understand 'Test123' while parsing into date.

The format of the String depends on the local date format, like 'mm/dd/yyyy' . If the parameter is not of this format  , date.parse will throw error.

Eg: r.Plan_Date__c = date.parse('12/27/2015');

You can also use date.valueOf(strDate) to parse string of format “yyyy-MM-dd HH:mm:ss” in the local time zone.

Please use this link to read about more date properties. https://developer.salesforce.com/docs/atlas.en-us.198.0.apexcode.meta/apexcode/apex_methods_system_date.htm#apex_System_Date_parse

This error is coming as system is not able to understand Test123 while parsing into date.

The format of the String depends on the local date format, like mm/dd/yyyy. If the parameter is not of this format, date.parse will throw error.

E.g.:

r.Plan_Date__c = date.parse('12/27/2015');

You can also use date.valueOf(strDate) to parse string of format yyyy-MM-dd HH:mm:ss in the local time zone.

Please use this link to read about more date properties.

Source Link
Nitin
  • 1.5k
  • 11
  • 10

THis error is coming as system is not able to understand 'Test123' while parsing into date.

The format of the String depends on the local date format, like 'mm/dd/yyyy' . If the parameter is not of this format , date.parse will throw error.

Eg: r.Plan_Date__c = date.parse('12/27/2015');

You can also use date.valueOf(strDate) to parse string of format “yyyy-MM-dd HH:mm:ss” in the local time zone.

Please use this link to read about more date properties. https://developer.salesforce.com/docs/atlas.en-us.198.0.apexcode.meta/apexcode/apex_methods_system_date.htm#apex_System_Date_parse