﻿<?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 - WebGrid: How to call the server side BatchUpdate method from the code behind</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-How-to-call-the-server-side-BatchUpdate-method-from-the-code-behind/</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>WebGrid: How to call the server side BatchUpdate method from the code behind</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-How-to-call-the-server-side-BatchUpdate-method-from-the-code-behind/</link><pubDate>Tue, 16 Aug 2011 16:26:32 GMT</pubDate><dc:creator>Riendy</dc:creator><description>&lt;p&gt;Hello Jocelyn,&lt;/p&gt;&lt;p&gt;&lt;br /&gt;I'm currently have not try to access the grid from a page method yet.&lt;br /&gt;Please give me a little time to check this out. I will let you know the updates soon.&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;Regards.&lt;br /&gt;Riendy&lt;/p&gt;</description></item><item><title>WebGrid: How to call the server side BatchUpdate method from the code behind</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-How-to-call-the-server-side-BatchUpdate-method-from-the-code-behind/</link><pubDate>Mon, 15 Aug 2011 16:36:19 GMT</pubDate><dc:creator>jcrendulic</dc:creator><description>&lt;p&gt;Thanks that helps...I also have another question.  How to I access the grid from a page method?  This is my page method function..&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;&lt;pre style="font-family: consolas; background: white; color: black; font-size: 13px"&gt;[&lt;span style="color: #2b91af"&gt;WebMethod&lt;/span&gt;(EnableSession&amp;nbsp;=&amp;nbsp;&lt;span style="color: blue"&gt;true&lt;/span&gt;)]
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color: blue"&gt;public&lt;/span&gt;&amp;nbsp;&lt;span style="color: blue"&gt;static&lt;/span&gt;&amp;nbsp;&lt;span style="color: blue"&gt;void&lt;/span&gt;&amp;nbsp;SaveAcctStatus(&lt;span style="color: blue"&gt;string&lt;/span&gt;&amp;nbsp;status,&amp;nbsp;&lt;span style="color: blue"&gt;string&lt;/span&gt;&amp;nbsp;name,&amp;nbsp;&lt;span style="color: blue"&gt;string&lt;/span&gt;&amp;nbsp;date,&amp;nbsp;&lt;span style="color: blue"&gt;string&lt;/span&gt;&amp;nbsp;typeofreturn)
&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;//Set some values and then update grid&lt;/pre&gt;&lt;pre style="font-family: consolas; background: white; color: black; font-size: 13px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/pre&gt;</description></item><item><title>WebGrid: How to call the server side BatchUpdate method from the code behind</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-How-to-call-the-server-side-BatchUpdate-method-from-the-code-behind/</link><pubDate>Mon, 15 Aug 2011 16:21:44 GMT</pubDate><dc:creator>Riendy</dc:creator><description>&lt;p&gt;Hi Jocelyn,&lt;br /&gt;&lt;br /&gt;To call BatchUpdate on WebGrid's event, you should use&lt;/p&gt;&lt;p /&gt;&lt;pre&gt;grdRecipMilestone.PerformBatchUpdate(true, true);&lt;/pre&gt;
&lt;p&gt;If you want to save all changes, set parameter 1 to true. If you set it into false, it means that cancel all changes. And parameter 2 is set to true. It is used to set the WebGrid UI to be updated and set false to be un-updated.&lt;/p&gt;
&lt;p&gt;PerformBatchUpdate method just updating the data on UI. The data just saved on cache and it is not update the database. However, this method call a batchUpdate event. In this event, you should get the data cache and update it into your database.&lt;/p&gt;
&lt;p&gt;Attached is my simple runable sample using button click to apply the changes.&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;Hope this helps.&lt;br /&gt;Riendy&lt;/p&gt;
&lt;p /&gt;
&lt;p&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;&lt;/p&gt;</description></item><item><title>WebGrid: How to call the server side BatchUpdate method from the code behind</title><link>http://www.intersoftsolutions.com/Community/WebGrid/WebGrid-How-to-call-the-server-side-BatchUpdate-method-from-the-code-behind/</link><pubDate>Mon, 15 Aug 2011 11:32:52 GMT</pubDate><dc:creator>jcrendulic</dc:creator><description>&lt;p&gt;I have a batchUpdtae method for the web grid in the codebehind page....&lt;/p&gt;&lt;pre style="font-family: consolas; background: white; color: black; font-size: 13px"&gt;&amp;nbsp;&lt;span style="color: blue"&gt;protected&lt;/span&gt;&amp;nbsp;&lt;span style="color: blue"&gt;void&lt;/span&gt;&amp;nbsp;grdRecipMilestone_BatchUpdate(&lt;span style="color: blue"&gt;object&lt;/span&gt;&amp;nbsp;sender,&amp;nbsp;&lt;span style="color: #2b91af"&gt;BatchUpdateEventArgs&lt;/span&gt;&amp;nbsp;e)
&amp;nbsp;{}&lt;/pre&gt;&lt;pre style="font-family: consolas; background: white; color: black; font-size: 13px"&gt;How do I call this method from the code behind page.  I already know how to from the client side (grdRecip.AcceptAllChanges()), but need to do it from the code behind page as well.&lt;/pre&gt;</description></item></channel></rss>