﻿<?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 - Different Values in NewRow and GridRow</title><link>http://www.intersoftsolutions.com/Community/WebGrid/Different-Values-in-NewRow-and-GridRow/</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>Different Values in NewRow and GridRow</title><link>http://www.intersoftsolutions.com/Community/WebGrid/Different-Values-in-NewRow-and-GridRow/</link><pubDate>Mon, 28 Jan 2013 22:47:28 GMT</pubDate><dc:creator>Hans</dc:creator><category>NewRow DropDownList Values Grid</category><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Thank you for sample.&lt;/p&gt;
&lt;p&gt;I have reviewed your sample and try to modify the sample so that perhaps similar with your current scenario.&lt;br&gt;&lt;/br&gt;Due to your WebGrid are using server side bind, therefore I add the validation code on InitializeRow server side event.&lt;br&gt;&lt;/br&gt;The validation code is to change the text of the Key cell to "None", if the text and the value if Key cell is the same.&lt;/p&gt;
&lt;p&gt;Here’s the snippet code on InitializeRow event:&lt;/p&gt;&lt;pre&gt;protected void tblDealClass_TargetByPeriodWebgrid_InitializeRow(object sender, RowEventArgs e)
{
    string keyText = e.Row.Cells.GetNamedItem("Key").Text;
    string keyValue = e.Row.Cells.GetNamedItem("Key").Value.ToString();
    // If the text and the value if Key cells is the same. Change the text to "None"
    if (keyText == keyValue)
        e.Row.Cells.GetNamedItem("Key").Text = "None";
}&lt;/pre&gt;
&lt;p&gt;Hope this helps.&lt;/p&gt;
&lt;p&gt;Thank you.&lt;/p&gt;
&lt;p&gt;Regards,&lt;br&gt;&lt;/br&gt;Hans.&lt;/p&gt;</description></item><item><title>Different Values in NewRow and GridRow</title><link>http://www.intersoftsolutions.com/Community/WebGrid/Different-Values-in-NewRow-and-GridRow/</link><pubDate>Mon, 28 Jan 2013 02:24:54 GMT</pubDate><dc:creator>Schrall</dc:creator><category>NewRow DropDownList Values Grid</category><description>Hallo Hans,&lt;br /&gt;&lt;br /&gt;Thank you for your Reply. &lt;br /&gt;&lt;br /&gt;I'am working with the Value List. Im building my value List in the init event from the Webgrid. Because i need Localized Date from a Database. &lt;br /&gt;&lt;br /&gt;But when i have Values that are not anymore in the List? Then it shows only the Id as you can see in my example. &lt;br /&gt;&lt;br /&gt;I need something like a clientside Cell create event, where i can Display my own Data based on the Cell value. &lt;br /&gt;&lt;br /&gt;Greetings from Bavaria&lt;br /&gt;&lt;br /&gt;Patrick&lt;br /&gt;</description></item><item><title>Different Values in NewRow and GridRow</title><link>http://www.intersoftsolutions.com/Community/WebGrid/Different-Values-in-NewRow-and-GridRow/</link><pubDate>Sun, 27 Jan 2013 22:13:50 GMT</pubDate><dc:creator>Hans</dc:creator><category>NewRow DropDownList Values Grid</category><description>&lt;p&gt;Hello,&lt;/p&gt;&lt;p&gt;Thank you for the question and please forgive me for lack of understanding about the reported problem.&lt;/p&gt;
&lt;p&gt;If you like to change the value like PeriodID to another value (for example: PeriodName), you could use WebValueList feature in WebGrid.&lt;br /&gt;&lt;br /&gt;With WebValueList, you can easily translate ID to Text Lookup by using the DataSource populated in the WebValueList object. For instance, the Supplier Name in the WebGrid above is actually an ID column which is translated to Company Name field of Suppliers table through WebValueList.&lt;/p&gt;
&lt;p&gt;Here’s I attached a simple WebGrid sample that using WebValueList feature.&lt;br /&gt;&lt;span style="font-size: 10pt;"&gt;In the sample, I bind WebGrid to access data source control (Northwind.mdb database, Order Details table &amp;amp; Products table).&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-size: 10pt;"&gt;Please kindly have review on my sample and let me know your response.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;For further information about WebValueList, you could see on WebGrid's documentation. &lt;/p&gt;
&lt;p&gt;Thank you.&lt;/p&gt;
&lt;p&gt;Regards,&lt;br /&gt;&lt;br /&gt;Hans.&lt;/p&gt;</description></item><item><title>Different Values in NewRow and GridRow</title><link>http://www.intersoftsolutions.com/Community/WebGrid/Different-Values-in-NewRow-and-GridRow/</link><pubDate>Fri, 25 Jan 2013 10:55:52 GMT</pubDate><dc:creator>Schrall</dc:creator><category>NewRow DropDownList Values Grid</category><description>&lt;p&gt;In our Grid we insert DateValues from a DropDownlist.  The User gets a List of the next 12 Month to Choose. The values are stored in a table and the key is the PeriodID&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;In the Grid we have values that are not listet anymore in the DropdownList. &lt;br /&gt;&lt;/p&gt;
&lt;p&gt;I would like to to Change the shown PeriodID to an Value of my own. Like an localized Date selected by the PeriodID. &lt;br /&gt;&lt;/p&gt;
&lt;p&gt;I'm not able to do an FullPostback, So i need something that works on the Clientside. &lt;/p&gt;
&lt;p&gt;Thanxs &lt;br /&gt;for your help.&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;</description></item></channel></rss>