infolink

Wednesday, December 14, 2011

How to fix Error in Module Settings page in DotNetNuke when getting Object reference not set to an instance of an object.

I started to create a new module using the DotNetNuke Starter Pack. I created all my controls and then got to the settings page. I didn't like the textbox and default controls, so I removed them, well after removing them, I started getting the error:
InnerException: Object reference not set to an instance of an object.
FileName:
FileLineNumber: 0
FileColumnNumber: 0
Method: DotNetNuke.UI.Containers.ActionButtonList.get_ModuleActions
StackTrace:
I had removed the following line from my module settings page:

<asp:textbox id="txtTemplate" cssclass="NormalTextBox" width="390" columns="30" textmode="MultiLine" rows="10" maxlength="2000" runat="server" />

It turns out that that control must be in your settings page or you will continue to get that error. So as a work around for now I put my control above it and set Visible="false", on the textbox. I figured I would pass this little tip as I saw many others reporting the same error, but never saw any solutions. This is what I came up with. Hope it helps someone else save some time.

No comments:

Post a Comment

Amazon1