icloud imap will not authorize through eM Client, Contacts and Calendar sync Ok Please Help...

I am trying to replace Outlook on Windows 10 with an email client that will do a better job of syncing with iCloud. I have set up eM Client so that it does sync with Contacts and Calendar (with the 2 stage deal Apple requires) but I cannot get IMAP to honor the Login in user name and apple generated password for the app.
Is there a solution to this?
Thanks for any assistance. Or other recommendations for an eMail client.
Lp

Check out this post, maybe it will help:  https://forum.emclient.com/emclient/topics/icloud-authorization-issues

Thanks for the link. I have already done this and this is how I was able to get Calendar and Contacts to sync. Using the same app specific password for IMAP does not work though. I still get Server says “{AUTHENTICATIONFAILED} Authentication Failed” message.

You can check that you have the correct port and security policy combination otherwise you will get an authentication error.

SMTP
Port 587 = Force usage of SSL/TLS
Port 25 = Use SSL/TLS if available
Port 465 = Use SSL/TLS on special port (legacy)

IMAP
Port 993 = Use SSL/TLS on special port (legacy)
Port 143 = Use SSL/TLS if available

POP3
Port 995 = Use SSL/TLS on special port (legacy)
Port 110 = Use SSL/TLS if available

These are the correct combinations of port and security policy. The underlined ones are the best option for security if your server supports them. SMTP port 465 was reassigned and should no longer be used for SMTP, though many mail providers still recommend and use it.

Thanks for the input.However, I still cannot access eMail. I have tried both settings for SMTP and IMAP and still cannot get past the Authentication Failed .There must be a solution to this! either that or no one can get eMail from their iCloud account.Calendar and Contacts still sync. Just not eMail. I have tried sending a test message as well and the SMTP side also rejects my login creds.Any suggestions to try would be most welcome.

NeverMind!Wrong Username spelling! It’s a almost forgotten item that was only in the outlook account settings.