zoukankan      html  css  js  c++  java
  • 在DNN的Forums上看到的对通用模块开发遇见的一些错误的回答

    文章的来源:http://www.dotnetnuke.com/Community/Forums/tabid/795/forumid/111/threadid/100778/scope/posts/Default.aspx

    Error:

    DotNetNuke.Services.Exceptions.ModuleLoadException: The type initializer for 'MyModule.DataProvider' threw an exception. ---> System.TypeInitializationException: The type initializer for 'MyModule.DataProvider' threw an exception. --->

    Answer:

    This is caused by upgrading your module from DNN3 to DNN4. In your dataprovider, Change:

    CType(Framework.Reflection.CreateObject("data", "MyModule", "MyModule.dll"), DataProvider)

    To:

    CType(Framework.Reflection.CreateObject("data", "MyModule", ""), DataProvider)

     Error:

    The module works fine when logged in as an administrator, but when a normal user uses it they do not get the post back click event or the page doesn't refresh.

    Answer:

    The module has caching enabled. Set the caching to 0 and click the update link in the module configuration settings for the module.

    Error:

    'ExecuteSQL' is not a member of ... 

    Answer:

    Use DotNetNuke.Data.DataProvider.Instance().ExecuteSQL...

    Error:

    Failed to generate a user instance of SQL Server due to a failure in starting the process for the user instance. The connection will be closed.

    Answer:

    Caused when using SQL Server express. In the web.config, change:

     <add name="SiteSqlServer" connectionString="Data Source=.\SQLExpress;AttachDbFilename=|DataDirectory|Database.mdf;Integrated Security=True;User Instance=True" providerName="System.Data.SqlClient" />

    to:

     <add name="SiteSqlServer" connectionString="Data Source=.\SQLExpress;AttachDbFilename=|DataDirectory|Database.mdf;Integrated Security=True;User Instance=False" providerName="System.Data.SqlClient" />
       

    Error:

    Exception has been thrown by the target of an invocation ... 

    Answer:

    If you have code that calls the database, ensure that a value is being returned fron the databse. Otherwise you will get this error.

    Error:

    The PopupControlExtender places the popup in the wrong place when the page is scrolled

    Answer:

    When the page scrolls, the popup control will lose position unless you place the items in a panel and give it a CssClass class like:

    < asp:Panel ID="pnlUsers" runat="server" Height="50px" Width="125px" CssClass="PanelExtender" >

    Then you give that .css class a  position of relative like:

    < style >
    .PanelExtender
    {
        position: relative;
    }
    < /style >



    Michael Washington
    * ADefWebserver.com
    * DNN Module Developer's Guide
    * IWEB - DNN Web Services
    * Silverlight and DotNetNuke
  • 相关阅读:
    Oracle SQL语句大全(一)
    数据查询(3)-复杂查询(芮)
    数据查询(2)-高级查询(芮)
    数据查询(1)-简单查询(芮)
    T-SQL(5)-操作数据行(芮)
    T-SQL(4)-功能函数(芮)
    T-SQL(3)-批处理(芮)
    T-SQL(2)-逻辑控制(芮)
    T-SQL(1)-变量(芮)
    如何设计数据库(2)?(芮)
  • 原文地址:https://www.cnblogs.com/GDLMO/p/1011785.html
Copyright © 2011-2022 走看看