Hello.
I have a ultrawebgrid with a cellButton column, I've tried diferent ways but cannot make the ClickCellButton to fire on server.
the button is like:
<igtbl:TemplatedColumn Type="Button" CellButtonDisplay="Always" Width="15px" Key="itemBTN" IsBound="false" AllowUpdate="No" BaseColumnName="Indicator" >
I tried with a template column, and the itemCommand is fired but , the button on it does not appear until the row is commited.
This is my code in DisplayLayout:
<DisplayLayout AllowColSizingDefault="Fixed" ScrollBar="Auto" BorderCollapseDefault="Separate"
Name="UltraWebGrid1" RowSelectorsDefault="yes" TableLayout="Fixed" Version="4.00"
UseFixedHeaders="True" AutoGenerateColumns="False" AllowDeleteDefault="Yes" AllowUpdateDefault="Yes" AllowAddNewDefault="Yes" FixedHeaderIndicatorDefault="None"
CellClickActionDefault ="Edit"
>
I tried with xmlLoadOnDemand = Acumulative, but does not work.
Please, help
Hello,
You can use the server event OnClick and handle it. Please take a look at the code below:
ASPX:<Bands> <igtbl:UltraGridBand> <Columns> <igtbl:TemplatedColumn> <CellTemplate> <asp:Button ID="Button1" runat="server" Text="Button" OnClick="Button1_Click" /> </CellTemplate> </igtbl:TemplatedColumn>C#:protected void Button1_Click(object sender, EventArgs e) { Label1.Text = "change"; }
Hope this helps.
Super, this example is fine, but have one more problem, when I add a new row, the button in the template doesn't get visible. I have "rowadding" enabled.