+ Start a Discussion
srujith chintha 4srujith chintha 4 

trailhead error dml operations

1.The Apex class must be called AccountHandler and be in the public scope
2.The Apex class must have a public static method called insertNewAccount
3.The method must accept an incoming string as a parameter, which will be used to create the Account name
4.The method must insert the account into the system and then return the record
5.The method must also accept an empty string, catch the failed DML and then return null.
Sai PraveenSai Praveen (Salesforce Developers) 
Hi Srujith,

Please note that Questions about how to pass Trailhead challenges are not on topic, because these challenges are intended to be independent demonstrations of your abilities.
Trailhead Help (https://trailhead.salesforce.com/en/help?support=home)

can provide assistance for situations where Trailhead does not appear to be functioning correctly.
You can reach out to them if this is the case.Hope above information helps.

Please mark as Best Answer so that it can help others in future.

Thanks,