Can anyone shed some light on this error?
System.ArgumentException: {"Key not foundParameter name: key"}
Message:Key not foundParameter name: key
StackTrace: at Infragistics.Shared.KeyedSubObjectsCollectionBase.GetItem(String key) at Infragistics.Win.UltraWinGrid.ColumnsCollection.get_Item(String key) at NBSControls.BondSourcesUsesBase.ugSources_InitializeLayout(Object sender, InitializeLayoutEventArgs e) in C:\Documents and Settings\mhsueh\My Documents\Visual Studio 2005\Projects\DFAST3\Controls\District\BondSourcesUsesBase.vb:line 29
FYI, I submitted this to support just now. Case Number: CAS-31347-KCMWBU
I thought about that as a possibility, but I stepped all of the code, plus searched for the phrases used in the tool tip through out the entire solution and could not find a match. I used NotePad++, "find in files" to do the search, since I do not have much luck with Windows search finding these types of things. I even went through the database to see if there were some, "user settings" and came up empty. I really picked a bad time to give up drinking. :-) Is there possibly a cache file, or some type of settings file the components have?
So something is changing the key of the tools back to their original values? And it's nothing in the code?
Then my guess is that you are calling the Load method on the Toolbars and loading them from a file at run-time.
also the call stack at the start of this thread is not mine. My stack trace is...
at Infragistics.Shared.KeyedSubObjectsCollectionBase.GetItem(String key) at Infragistics.Win.UltraWinToolbars.ToolsCollectionBase.get_Item(String key) at TraxView.SupportManagement.TicketEdit.BindWindowsToStateButtons() in C:\Source-AgTrax\TVCRM\TraxView\SupportManagement\TicketEdit.cs:line 1042
Yes. I get numerous exceptions that have nothing to do with the UltraToolBar until I eventually hit the break I put in to step through the first line that throws the "key not found" exception. This is really perplexing as if I put the real key value in, it falls over. If I put back in the original key value, it works, shows the caption values that no longer exist in the toolbar. This should have been very simple. I have a task to take all of the times "Organization" is used and replace that with "Account". I have scrubbed and searched every file in that project's directory and cannot find any places where "Organization" is still in any property of the UltraToolBar control in question. However, when I execute the code with this line...
toolbarManager.Tools["Open Tickets for Account"].ToolClick += new ToolClickEventHandler(TicketList_ToolClick);
The app falls over with the key not found error. Yet if I change it back to...
toolbarManager.Tools["Open Tickets for Organization"].ToolClick += new ToolClickEventHandler(TicketList_ToolClick);
it runs and when you hover over any of the buttons that have had, both their key and caption values renamed to account, they still show as Organization. I have ran "Clean Project", deleted all object, binaries, etc., recompiled and still get the same behavior. How can the toolbar manager keep this information when every text entry has been modified. I even saved the toolbar configuration to a XML file, modified all occurrences of Organization, reloaded the configuration and verified the values were modified in the toolbar manager. This is getting very frustrating so any ideas will be greatly appreciated.