Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...Module is one step closer to working, getting System.Argument ExceptionModule is one step closer to working, getting System.Argument Exception
Previous
 
Next
New Post
3/31/2008 2:17 PM
 

I am going to get this page working if it 's the last thing i do!!!

 

So NOW I put my code in the module, via Visual Studio, to do what I want it to do.  I saved it and now I get the error.  I'll keep looking, but if any of you experienced folk can point me in the appropriate direction, I'd appreciate it!

 

Thanks!

 

AssemblyVersion: 04.04.00
PortalID: -1
PortalName:
UserID: -1
UserName:
ActiveTabID: -1
ActiveTabName:
RawURL: /website/tabid/166/default.aspx
AbsoluteURL: /website/Default.aspx
AbsoluteURLReferrer:
UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.13) Gecko/20080311 Firefox/2.0.0.13
DefaultDataProvider: DotNetNuke.Data.SqlDataProvider, DotNetNuke.SqlDataProvider
ExceptionGUID: 154f53a5-1bb0-42f8-a27d-147f716260f6
InnerException: An item with the same key has already been added.
FileName:
FileLineNumber: 0
FileColumnNumber: 0
Method: System.ThrowHelper.ThrowArgumentException
StackTrace:
Message: System.ArgumentException: An item with the same key has already been added.at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource)at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add)at DotNetNuke.Entities.Modules.ModuleController.FillModuleInfoDictionary(IDataReader dr)
Source:

 
New Post
4/22/2008 4:55 AM
 

Same here (v4.8.2) after adding my module....
Unfortunally not solution yet.

 
New Post
4/22/2008 5:48 AM
 

Have you found any solution to this problem?
It seems to me that the framework executes the GetTabModules stored procedure and tries to build up a dictionary with ModuleInfo's.
Unfortunally, GetTabModules not onlyt returns the modules, but also the controls per module.

I've got a module with multiple controls, so GetTabModules retrieves multiple records for one module.
Because the ModuleId is used as the key in the dictionary it fails.....
Still no solution though.

From GetTabModules:

//Get modules form Database
modules = FillModuleInfoDictionary(DataProvider.Instance().GetTabModules(TabId));

From FillModuleInfoDictionary:

 private Dictionary<int, ModuleInfo> FillModuleInfoDictionary(IDataReader dr)
        {
            Dictionary<int, ModuleInfo> dic = new Dictionary<int, ModuleInfo>();
            try
            {
                while (dr.Read())
                {
                    // fill business object
                    ModuleInfo obj = FillModuleInfo(dr, false, true);
                    // add to dictionary
                    dic.Add(obj.ModuleID, obj);
                }

 
New Post
4/22/2008 6:09 AM
 

Workaround: remove all but one control from your ModuleDefinition (I only needed one, because I use an usercontrol injector)

 
New Post
5/25/2009 6:46 PM
 

I'm having the the same problem. I'm runing DNN 4.9.4. Not sure it's caused by the recent upgrade or it happened before the upgrade.


Frank Wang
 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...Module is one step closer to working, getting System.Argument ExceptionModule is one step closer to working, getting System.Argument Exception


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out