I am using below code to copy data.
elements = this.Where(el => !el.Key.StartsWith("."))
.ToDictionary(el => el.Key, el => el.Value
.ToDictionary(p => p.Key, p => p.Value));
It throws error if key already added. I used Distinct() method too. But no luck.
Can you please any body help me out.
Thanks in advance
first check with Any() if it exists
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)