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

HomeHomeOur CommunityOur CommunityGeneral Discuss...General Discuss...DataProvider - Argument CanDataProvider - Argument Can't be Null?
Previous
 
Next
New Post
1/6/2007 1:18 AM
 
Hello,

Wondering if anyone knows what is going on with my custom module.  It works fine on my development machine but on my server the module is throwing this error:

DotNetNuke.Services.Exceptions.ModuleLoadException: The type initializer for "Ryno.DNN.Modules.ReferAbro.Data.DataProvider" threw an exception. ---> System.TypeInitializationException: The type initializer for "Ryno.DNN.Modules.ReferAbro.Data.DataProvider" threw an exception. ---> System.ArgumentNullException: Value cannot be null. Parameter name: type at System.Activator.CreateInstance(Type type, Boolean nonPublic) at DotNetNuke.Framework.Reflection.CreateObject(String TypeName, String CacheKey) at DotNetNuke.Framework.Reflection.CreateObject(String ObjectProviderType, String ObjectProviderName, String ObjectNamespace, String ObjectAssemblyName) at DotNetNuke.Framework.Reflection.CreateObject(String ObjectProviderType, String ObjectNamespace, String ObjectAssemblyName) at Ryno.DNN.Modules.ReferAbro.Data.DataProvider.CreateProvider() at Ryno.DNN.Modules.ReferAbro.Data.DataProvider..cctor() --- End of inner exception stack trace --- at Ryno.DNN.Modules.ReferAbro.Data.DataProvider.Instance() at Ryno.DNN.Modules.ReferAbro.Business.RynoReferABroController.ListRynoReferABroUnregistered() at Ryno.DNN.Modules.ReferAbro.ReferAbro.ProcessPoints() at Ryno.DNN.Modules.ReferAbro.ReferAbro.Page_Load(Object sender, EventArgs e) --- End of inner exception stack trace ---

And yet the .ListRynoReferABroUnregistered function is in my DAL and the Stored Procedure is there. It doesn't pass any values and simply retrieves some records into an array.  Here are the snippets from my DAL:

From the Dataprovider:
Public MustOverride Function ListRynoReferABroUnregistered() As IDataReader

From the Controller:
Public Function ListRynoReferABroUnregistered() As ArrayList
            Return CBO.FillCollection(DataProvider.Instance().ListRynoReferABroUnregistered(), GetType(RynoReferABroInfo))
End Function

From the SQLDataProvider:
Public Overrides Function ListRynoReferABroUnregistered() As IDataReader
            Return CType(SqlHelper.ExecuteReader(ConnectionString, DatabaseOwner & ObjectQualifier & "ListRynoReferABroUnregistered"), IDataReader)
 End Function

My SP doesn't accept any variables and works fine on my local machine.  I'm not sure what is going on here.  Very odd.

I'm using DNN3.2.2 by the way.  Thanks for any help.

I'm too poor for anything other than the community version
 
New Post
1/6/2007 1:33 AM
 
I changed it so that it accepts a value in the function....the SP doesn't do anything with the value.  But this didn't change anything.  So I'm not sure what it's talking about is NULL?

This is really boggling my mind.

I'm too poor for anything other than the community version
 
New Post
1/6/2007 1:52 AM
 
So I changed the name of the function/stored procedure.  Same problem.  I am at a complete loss.

I have several other functions in the same Class...using Stored Procedures on the same table....returning data back into the same datatype.  Why this one is throwing a fit is beyond me.  Nothing about it stands out.

Help?

I'm too poor for anything other than the community version
 
New Post
1/6/2007 2:10 AM
 
Disregard.

It helps when you put the SqlDataProvider.dll into the .dnn file of the PA.

I keep forgetting that the "create PA" of the File Manager doesn't add that.  Doh.

I'm too poor for anything other than the community version
 
New Post
1/6/2007 7:49 AM
 

I am glad you found the answer and made a post to help others.

I am curious, not criticizing, do you have plans to use DotNetNuke 4? When using these methods:

  • Setting-up the Environment (using IIS)
  • Setting-up the Environment (without IIS)
  • The PA packager packages everything.



    Michael Washington
    http://ADefWebserver.com
    www.ADefHelpDesk.com
    A Free Open Source DotNetNuke Help Desk Module
     
    Previous
     
    Next
    HomeHomeOur CommunityOur CommunityGeneral Discuss...General Discuss...DataProvider - Argument CanDataProvider - Argument Can't be Null?


    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