﻿<?xml version="1.0" encoding="utf-8"?><rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:media="http://search.yahoo.com/mrss/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0"><channel><title>Intersoft Community - WebGrid Enterprise - How to get celltemplate value at serverside click event</title><link>http://www.intersoftsolutions.com/Community/WebGrid/How-to-get-celltemplate-value-at-serverside-click-event/</link><description /><generator>http://www.intersoftsolutions.com</generator><language>en</language><copyright>Copyright 2002 - 2015 Intersoft Solutions Corp. All rights reserved.</copyright><ttl>60</ttl><item><title>How to get celltemplate value at serverside click event</title><link>http://www.intersoftsolutions.com/Community/WebGrid/How-to-get-celltemplate-value-at-serverside-click-event/</link><pubDate>Tue, 01 Jul 2014 22:41:23 GMT</pubDate><dc:creator>Hans</dc:creator><description>&lt;p&gt;Hello,&lt;br&gt;&lt;br&gt;I’m glad to hear that you have resolved the get cell template value scenario.&lt;br&gt;&lt;br&gt;Regarding your CalendarCombo issue, since this issue was different with the first one, please kindly create a new thread for this issue.&lt;br&gt;&lt;br&gt;While creating the new thread, please kindly provide us more information regarding this CalendarCombo issue.&lt;br&gt;For example, what is your webpage DOCTYPE?&lt;br&gt;What is your WebGrid configuration? What is your current WebGrid assembly version?&lt;br&gt;&lt;br&gt;And if possible, could you provide the simple working sample regarding this issue.&lt;br&gt;&lt;br&gt;Thank you very much for your help.&lt;br&gt;&lt;br&gt;Regards,&lt;br&gt;Hans K.&lt;br&gt;&lt;/p&gt;</description></item><item><title>How to get celltemplate value at serverside click event</title><link>http://www.intersoftsolutions.com/Community/WebGrid/How-to-get-celltemplate-value-at-serverside-click-event/</link><pubDate>Tue, 01 Jul 2014 07:51:43 GMT</pubDate><dc:creator>x-rookie</dc:creator><description>&lt;p&gt;I use your method and solve the problem.Deeply thanks for your help.&lt;/p&gt;&lt;p&gt;In my latest reply,I found an error using CalendarCombo In webgrid In HTML5 mode.It can only input the number but can't use the calendar control.So could you tell this bug to the research and develop team to fix it?Thank you &lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>How to get celltemplate value at serverside click event</title><link>http://www.intersoftsolutions.com/Community/WebGrid/How-to-get-celltemplate-value-at-serverside-click-event/</link><pubDate>Tue, 01 Jul 2014 02:51:41 GMT</pubDate><dc:creator>Hans</dc:creator><description>&lt;p&gt;Hello,&lt;br&gt;&lt;br&gt;Thank you for the reply.&lt;br&gt;&lt;br&gt;If you want to get the checked row and get row object from the child table, you should modify the code.&lt;br&gt;&lt;br&gt;I have a WebGrid page with hierarchical mode and checkbox column in child table.&lt;br&gt;&lt;br&gt;Like in the WebGrid page in my prior post, there is an ASP.Net button control to get the checked row.&lt;br&gt;Here’s the snippet code to get the checked row in button click event:&lt;br&gt;&lt;/p&gt;&lt;pre&gt;protected void Button1_Click(object sender, EventArgs e){
    ArrayList checkedRows = WebGrid1.RootTable.ChildTables.GetNamedItem("Orders").GetCheckedRows();
        
    string text = "Checked rows: " + checkedRows.Count + "\n\n";

    foreach (object keyValue in checkedRows)
    {
        text += WebGrid1.RootTable.ChildTables.GetNamedItem("Orders").Rows.GetRowByKeyValue(keyValue.ToString()).Cells[3].Value.ToString() + "\n";
    }

    TextBox1.Text = text;
}&lt;/pre&gt;&lt;p&gt;To get the row object from child table, you should set the “RestoreExpandedChildRows” property, under “LayoutSettings” tag, to “True”.&lt;br&gt;&lt;br&gt;Please kindly have review on the attached page to see result. To run the page, you could add the page to the WebGrid Solution Samples.&lt;br&gt;&lt;br&gt;Hope this helps.&lt;br&gt;&lt;br&gt;Regards,&lt;br&gt;Hans K.&lt;br&gt;&lt;/p&gt;</description></item><item><title>How to get celltemplate value at serverside click event</title><link>http://www.intersoftsolutions.com/Community/WebGrid/How-to-get-celltemplate-value-at-serverside-click-event/</link><pubDate>Fri, 27 Jun 2014 20:18:50 GMT</pubDate><dc:creator>x-rookie</dc:creator><description>&lt;p&gt;I apologize for the late response.&lt;/p&gt;&lt;p&gt;I use your opinion but when the program run at the sentence like " WebGrid1.RootTable.Rows.GetRowByKeyValue(keyValue.ToString()).Cells[3].Value.ToString() ",it called error.The WebgridRow object is null.The GetRowByKeyValue returns the webgridrow object,but it is null,Now I find why the error occurs.My webgrid has parent datamember and child datamember.When I select the parent rows ,this sentence is OK,but the child rows is wrong.So how can I get the child rows by GetRowByKeyValue?&lt;/p&gt;&lt;p&gt;By the way,I found an error in using webgrid in the latest version.The environment is that the webgrid is hierachical,in the childtable,there is a calendarCombo column,it can't work to select date in HTML5 mode,so please check it and fix the error as soon as possible,thank you&lt;/p&gt;</description></item><item><title>How to get celltemplate value at serverside click event</title><link>http://www.intersoftsolutions.com/Community/WebGrid/How-to-get-celltemplate-value-at-serverside-click-event/</link><pubDate>Tue, 17 Jun 2014 23:16:08 GMT</pubDate><dc:creator>Hans</dc:creator><description>&lt;p&gt;Hello,&lt;br&gt;&lt;br&gt;I apologize for the late response.&lt;br&gt;&lt;br&gt;Since you can get the key value each checked row, you could use GetRowByKeyValue() WebGrid’s method.&lt;br&gt;With this method you could get WebGridRow object, then you could get CellTemplate column value.&lt;br&gt;&lt;br&gt;I modify the attached sample that I provide to you in my prior post.&lt;br&gt;I add one Checker column to the WebGrid and I modify the Button click event code.&lt;br&gt;&lt;/p&gt;&lt;pre&gt;protected void Button1_Click(object sender, EventArgs e){
    ArrayList checkedRows = WebGrid1.RootTable.GetCheckedRows();
    string text = "Checked rows: " + checkedRows.Count + "\n\n";

    foreach (string keyValue in checkedRows)
    {
        text += WebGrid1.RootTable.Rows.GetRowByKeyValue(keyValue.ToString()).Cells[3].Value.ToString() + "\n";
    }

    TextBox1.Text = text;
}&lt;/pre&gt;&lt;p&gt;Hope this helps.&lt;br&gt;Thank you.&lt;br&gt;&lt;br&gt;Regards,&lt;br&gt;Hans K.&lt;br&gt;&lt;/p&gt;</description></item><item><title>How to get celltemplate value at serverside click event</title><link>http://www.intersoftsolutions.com/Community/WebGrid/How-to-get-celltemplate-value-at-serverside-click-event/</link><pubDate>Sun, 15 Jun 2014 21:36:50 GMT</pubDate><dc:creator>x-rookie</dc:creator><description>&lt;p&gt;I am sorry that I don't explain the problem clearly.&lt;/p&gt;&lt;p&gt;I want to batch update in serverside click event,but the condition is that when I select&amp;nbsp;several rows by webgrid row checker,how can I get the selected rows celltemplate value at serverside click event.&lt;/p&gt;&lt;p&gt;I can only get the selected row key values by this:&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ArrayList selectList = wg_sys_function.GetTableByName("TSysFunction").GetCheckedRows(); &lt;/p&gt;&lt;p&gt;But how can I get the selected row celltemplate value like radiobutton value.Thank you&lt;br&gt;&lt;/p&gt;</description></item><item><title>How to get celltemplate value at serverside click event</title><link>http://www.intersoftsolutions.com/Community/WebGrid/How-to-get-celltemplate-value-at-serverside-click-event/</link><pubDate>Fri, 13 Jun 2014 03:59:29 GMT</pubDate><dc:creator>Hans</dc:creator><description>&lt;p&gt;Hello,&lt;br&gt;&lt;br&gt;Thank you for the question.&lt;br&gt;&lt;br&gt;I made a page that contains WebGrid with CellTemplate feature.&lt;br&gt;I bind the WebGrid to access data source control (Northwind.mdb database &amp;amp;  Customers table).&lt;br&gt;I add an ASP button to the page to get the CellTemplate value.&lt;br&gt;&lt;br&gt;So I add a line of code to get the first row CellTemplate column (ContactName column).&lt;br&gt;&lt;/p&gt;&lt;pre&gt;protected void Button1_Click(object sender, EventArgs e){
    Label3.Text = WebGrid1.RootTable.Rows[0].Cells[2].Value.ToString();
}
&lt;/pre&gt;&lt;p&gt;Please kindly have review on the sample to see the result.&lt;br&gt;You also could download the sample from this link: http://1drv.ms/1qEvgRc&lt;br&gt;&lt;br&gt;Thank you.&lt;br&gt;&lt;br&gt;Regards,&lt;br&gt;Hans K.&lt;br&gt;&lt;/p&gt;</description></item><item><title>How to get celltemplate value at serverside click event</title><link>http://www.intersoftsolutions.com/Community/WebGrid/How-to-get-celltemplate-value-at-serverside-click-event/</link><pubDate>Thu, 12 Jun 2014 03:07:03 GMT</pubDate><dc:creator>x-rookie</dc:creator><description>&lt;!--StartFragment --&gt;&lt;div&gt;
I&amp;nbsp;use&amp;nbsp;webgrid&amp;nbsp;with&amp;nbsp;celltemplate&amp;nbsp;as&amp;nbsp;follows:&lt;br&gt;&amp;lt;Columns&amp;gt;&lt;br&gt;&amp;lt;ISWebGrid:WebGridColumn&amp;nbsp;AllowGrouping="No"&amp;nbsp;AllowSizing="No"&amp;nbsp;AllowSorting="No"&amp;nbsp;Bound="False"&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;Caption="choose"&amp;nbsp;ColumnType="CheckBox"&amp;nbsp;EditType="NoEdit"&amp;nbsp;IsRowChecker="True"&amp;nbsp;Name="sub_module_select"&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;ShowInSelectColumns="No"&amp;nbsp;Width="30px"&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;CellStyle&amp;nbsp;Cursor="Hand"&amp;nbsp;HorizontalAlign="Center"&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;/CellStyle&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;HeaderStyle&amp;nbsp;HorizontalAlign="Center"&amp;nbsp;VerticalAlign="Middle"&amp;nbsp;/&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;ButtonStyle&amp;nbsp;CssClass="clsButton"&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;/ButtonStyle&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;/ISWebGrid:WebGridColumn&amp;gt;&lt;br&gt;&amp;lt;ISWebGrid:WebGridColumn&amp;nbsp;Caption="edit"&amp;nbsp;DataMember="f_access_flag"&amp;nbsp;ColumnType="Template"&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;Width="150px"&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;CellTemplate&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;asp:RadioButton&amp;nbsp;ID="radAccessEdit"&amp;nbsp;runat="server"&amp;nbsp;Text="editable"&amp;nbsp;Checked="true"&amp;nbsp;GroupName="access"&amp;nbsp;/&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;asp:RadioButton&amp;nbsp;ID="radAccessQuery"&amp;nbsp;runat="server"&amp;nbsp;Text="view only"&amp;nbsp;GroupName="access"&amp;nbsp;/&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;/CellTemplate&amp;gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;/ISWebGrid:WebGridColumn&amp;gt;&lt;br&gt;&amp;lt;/Columns&amp;gt;&lt;br&gt;&lt;br&gt;I&amp;nbsp;can&amp;nbsp;get&amp;nbsp;the&amp;nbsp;each&amp;nbsp;radiobutton&amp;nbsp;value&amp;nbsp;in&amp;nbsp;InitialRow&amp;nbsp;event,but&amp;nbsp;how&amp;nbsp;can&amp;nbsp;i&amp;nbsp;get&amp;nbsp;these&amp;nbsp;values&amp;nbsp;in&amp;nbsp;serverside&amp;nbsp;event,&lt;br&gt;I&amp;nbsp;don't&amp;nbsp;want&amp;nbsp;to&amp;nbsp;update&amp;nbsp;each&amp;nbsp;row&amp;nbsp;in&amp;nbsp;UpdateRow&amp;nbsp;event,I&amp;nbsp;want&amp;nbsp;to&amp;nbsp;batch&amp;nbsp;update&amp;nbsp;in&amp;nbsp;serverside&amp;nbsp;click&amp;nbsp;event,so&amp;nbsp;how&amp;nbsp;can&amp;nbsp;I&amp;nbsp;get&amp;nbsp;these&amp;nbsp;values?&lt;br&gt;
&lt;/div&gt;</description></item></channel></rss>