Technical support This forum is closed.
Version 1.x > Technical support > CMSRepeater containing buttons? View modes: 
User avatar
Member
Member
wtijsma - 5/23/2005 4:25:56 PM
   
CMSRepeater containing buttons?
Hi,

How can I use buttons inside the Kentico ListControls?

You're calling databind() from within the control, and now the the ItemCommand event never gets raised.

I would advise against it, as there are many situations where databinding isn't wanted, for example in a postback where the data is saved ViewState, or in this case, if actions from the listcontrol are required.

User avatar
Member
Member
cpaul - 5/26/2005 4:46:46 PM
   
Re: CMSRepeater containing buttons?
As a work-around, you could derive a user control from the Kentico InlineUserControl, and add it to the stylesheet the repeater is using by putting something like %%control.ButtonWrapper.ascx%%, but you'd be limited to passing one parameter.

I have some code that provides better control insertion when parsing XML, it wouldn't take long to replace the kentico xsl processor with it. My version allows either user or server controls, requires no base class, and unlimited number of named parameters. I sent it to Petr, so maybe it'll make it's way in eventually, but I can email you a copy if you'd like.

User avatar
Member
Member
wtijsma - 5/28/2005 3:17:57 PM
   
Re: CMSRepeater containing buttons?
Hi Chip,

I'd be interested to take a look at it.
I worked around it by just using a regular asp:repeater and the API to retrieve the data.

Wiebe