Module's event from repeater

This is the place to report bugs and get support. When posting in this forum, please always provide as much detail as possible.

Please do not report problems with a custom build or custom code in this forum. If you are producing your own build from the source code and have problems or questions, ask in the developer forum, do not report it as a bug.

This is the place to report bugs and get support

When posting in this forum, please try to provide as many relevant details as possible. Particularly the following:

  • What operating system were you running when the bug appeared?
  • What database platform is your site using?
  • What version of mojoPortal are you running?
  • What version of .NET do you use?
  • What steps are necessary to reproduce the issue? Compare expected results vs actual results.
Please do not report problems with a custom build or custom code in this forum. If you are producing your own build from the source code and have problems or questions, ask in the developer forum.
This thread is closed to new posts. You must sign in to post in the forums.
11/24/2006 9:59:38 PM
Gravatar
Total Posts 7

Module's event from repeater

Hi, Joe

I encountered one problem today with my module for mojoPortal (mojoportal-2-1-4):
when I add some repeater to a module, e.g.:

<asp:Repeater ID="rptList" runat="server" OnItemCommand="rptList_ItemCommand">
    <ItemTemplate>
        <asp:Button ID="Button1" runat="server" CommandName="MyButton" Text="AAA" />
    </ItemTemplate>
</asp:Repeater>

events from controls inside repeater are not fired. I.e. when you press Button1, the "rptList_ItemCommand" is not called.
The most strange thing - when I directly place the same module control (.ascx) on a blank .aspx page, events from repeater work just fine.
Have you any ideas?

Vitaly.
11/25/2006 1:51:40 AM
Gravatar
Total Posts 18439

Re: Module's event from repeater

Hi Vitaly,

Yes I think I know the cause and solution. In mojoPortal, to increase performance I have ViewState disabled in the page by default which makes the amount of text sent to the browser smaller.
If a module requires ViewState for postback events you can simply add this in Page Load event of the module:

Page.EnableViewState = true;

Hope it helps,

Joe
11/25/2006 6:38:27 PM
Gravatar
Total Posts 7

Re: Module's event from repeater

Yes, thank you, that was the reason.
You must sign in to post in the forums. This thread is closed to new posts.