These forums are read-only and considered to be an archive. Please use the new Community for future interaction and posts.

An entry with the same key already exists.

Server Error in '/FileVista' Application.
--------------------------------------------------------------------------------

An entry with the same key already exists. 
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.ArgumentException: An entry with the same key already exists.

Source Error: 

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.  

Stack Trace: 


[ArgumentException: An entry with the same key already exists.]
   System.ThrowHelper.ThrowArgumentException(ExceptionResource resource) +50
   System.Collections.Generic.TreeSet`1.Add(T item) +246
   System.Collections.Generic.SortedDictionary`2.Add(TKey key, TValue value) +88
   GleamTech.FileVista.SetupPage.Page_Load(Object sender, EventArgs e) +619
   System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +13
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +45
   System.Web.UI.Control.OnLoad(EventArgs e) +80
   System.Web.UI.Control.LoadRecursive() +49
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3745

 
----------

I'm use the trial version, any sugestion?
Laura Gimeno Losantos 7/12/2007 3:50 AM
Hi,
In some cultures like spanish, culture names are not unique thus an error occurs for the duplicated names. I have sent you an email regarding the fix.
Cem Alacayir 8/24/2007 5:31 AM
I`ve the same error, can u send me the fix ASAP pls?

tnks!
Diego Majlis 8/28/2007 6:57 AM
Ok, I have sent you the fix.
Cem Alacayir 8/28/2007 3:23 PM
I am having the same issue too. Can someone help me out?
VR 10/12/2011 4:19 AM
This error was related to an old version of FileVista. According to our records, you have a FileVistaControl license. I guess your issue is different. If you specify the exact error message, we can help you better.
Cem Alacayir 10/12/2011 12:22 PM
Thanks for your reply.
This is the error we are getting.

An Error Occured:

System.ArguementException: Item has already been added. Key in dictionary: 'New Folder' Key Being added: 'New Folder' 
at System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add)
at System.Collections.Hashtable.Add(Object key, Object value)
at GleamTech.IO.FBKFile.GetFileOrderOrCreate(String path)
at GleamTech.IO.FileOperation.GetFiles(Boolean includeHidden, Boolean includeSystem)
at GleamTech.Web.Controls.FileVistaWebService.GetList(Int32 rootFolderID, String relativePath, Int32 selectTree, Int32 isRefresh)
VR 10/12/2011 12:36 PM
This error comes from .NET framework, it seems there are multiple files with the same name "'New Folder" in the folder.
Please check if you have a subfolder named "New Folder" and also a file named "New Folder".
Cem Alacayir 10/12/2011 1:16 PM
We have around 3 subfolders (in different locations) by name 'New folder', but not any files. 
On our website, users can create folders and upload documents and they can give any name to the folders and files. But it should not cause an issue if the folders with same name are in different locations. right?

Also, in some cases we are getting the below error. This is not consistant, but happens with only a few folders. Do  you  know the reason this is happening?

An error occured

System.NullreferenceException: Object reference not set to an instance of object.
at GleamTech.IO.FileOperation.GetFolder(Boolean includeHidden, Boolean includeSystem)
at GleamTech.Web.Controls.FileVistaWebservice.GetList(int rootFolderID, string relativePath, int selectTree, int isRefresh)
VR 10/13/2011 3:42 AM
I looked again at the first error message and noticed this line:

at GleamTech.IO.FBKFile.GetFileOrderOrCreate(String path)

There is no method like this in GleamTech's library. It seems you modified the source code.
The second error may also be related to your custom code.
Please check your custom code for the cause of these errors.
Cem Alacayir 10/13/2011 1:13 PM