Click here to Skip to main content
15,881,092 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
The following error keeps on disconnecting my software from my server...
(A dialog box pops up with this continuously until I close the software)

S - FMTT2

System.ArgumentException: An entry with the same key already exists.
at System.Collections.Specialized.ListDictionary.Add(Object key, Object value)
at System.Collections.Specialized.HybridDictionary.Add(Object key, Object value)
at Khendys.Controls.ExRichTextBox..ctor()
at Instant_Messaging.InstantMessaging.InitializeComponent()
at Instant_Messaging.InstantMessaging..ctor()
at SalonwareNET.frmInstantMessaging.InitializeComponent()
at SalonwareNET.frmInstantMessaging..ctor()
at SalonwareNET.frmMain.Timer1_Tick(Object sender, EventArgs e)



It also pops up when I try to use the Instant Messaging feature in the software.


By the looks of it, I have duplicate keys somewhere and it doesn't know which one to choose. But I have no coding experience.


What am I looking for and how I would I go about finding it?



Thank you in advance and apologize if it's a simple fix.


BG
Posted
Comments
Tomas Takac 18-Dec-14 16:39pm    
Well the error pops up continuously because it happens in the timer tick event. The real problem is in ExRichTextBox constructor though when I have to guess. I'd have a look at the code there and try to figure out why it's adding the duplicate key.
Philippe Mori 18-Dec-14 20:55pm    
Run the application Under a debugger with the option to stop when the exception occurs. At that point, inspect the key and the content of the dictionary. It should then be very trivial to determine the problem.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900