﻿<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/"><channel><title>博客园-一品梅-最新评论</title><link>http://www.cnblogs.com/onlyendure/CommentsRSS.aspx</link><description /><language>zh-cn</language><pubDate>Mon, 11 Aug 2008 01:35:27 GMT</pubDate><lastBuildDate>Mon, 11 Aug 2008 01:35:27 GMT</lastBuildDate><generator>cnblogs</generator><item><title>re: ObjectDataSource.Selected Event</title><link>http://www.cnblogs.com/onlyendure/archive/2008/07/09/1238805.html#1249527</link><dc:creator>大宋提刑官</dc:creator><author>大宋提刑官</author><pubDate>Wed, 09 Jul 2008 05:33:48 GMT</pubDate><guid>http://www.cnblogs.com/onlyendure/archive/2008/07/09/1238805.html#1249527</guid><description><![CDATA[ObjectDataSourceMethodEventArgs..::.InputParameters Property <br><a href="http://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.objectdatasourcemethodeventargs.inputparameters.aspx" target="_new">http://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.objectdatasourcemethodeventargs.inputparameters.aspx</a><br><br><div align=right><a style="text-decoration:none;" href="http://www.cnblogs.com/onlyendure/" target="_blank">大宋提刑官</a> 2008-07-09 13:33 <a href="http://www.cnblogs.com/onlyendure/archive/2008/07/09/1238805.html#1249527#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>re: ObjectDataSource.Selected Event</title><link>http://www.cnblogs.com/onlyendure/archive/2008/07/09/1238805.html#1249488</link><dc:creator>大宋提刑官</dc:creator><author>大宋提刑官</author><pubDate>Wed, 09 Jul 2008 05:01:53 GMT</pubDate><guid>http://www.cnblogs.com/onlyendure/archive/2008/07/09/1238805.html#1249488</guid><description><![CDATA[ObjectDataSourceStatusEventArgs Class<br><a href="http://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.objectdatasourcestatuseventargs.aspx" target="_new">http://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.objectdatasourcestatuseventargs.aspx</a><br><br><br>-----------------------------------------------<br>&lt;%@ Register TagPrefix=&quot;aspSample&quot; Namespace=&quot;Samples.AspNet.CS&quot; Assembly=&quot;Samples.AspNet.CS&quot; %&gt;<br>&lt;%@ Import namespace=&quot;Samples.AspNet.CS&quot; %&gt;<br>&lt;%@ Page language=&quot;c#&quot; %&gt;<br>&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Transitional//EN&quot;<br>    &quot;<a href="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd&quot;&gt;" target="_new">http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd&quot;&gt;</a><br>&lt;script runat=&quot;server&quot;&gt;<br>private void NorthwindEmployeeDeleting(object source, ObjectDataSourceMethodEventArgs e)<br>{<br>  // The GridView passes the ID of the employee<br>  // to be deleted. However, the buisiness object, EmployeeLogic,<br>  // requires a NorthwindEmployee parameter, named &quot;ne&quot;. Create<br>  // it now and add it to the parameters collection.<br>  IDictionary paramsFromPage = e.InputParameters;<br>  if (paramsFromPage[&quot;EmpID&quot;] != null) {<br>    NorthwindEmployee ne<br>      = new NorthwindEmployee( Int32.Parse(paramsFromPage[&quot;EmpID&quot;].ToString()));<br>    // Remove the old EmpID parameter.<br>    paramsFromPage.Clear();<br>    paramsFromPage.Add(&quot;ne&quot;, ne);<br>  }<br>}<br><br>private void NorthwindEmployeeDeleted(object source, ObjectDataSourceStatusEventArgs e)<br>{<br>  // Handle the Exception if it is a NorthwindDataException<br>  if (e.Exception != null)<br>  {<br><br>    // Handle the specific exception type. The ObjectDataSource wraps<br>    // any Exceptions in a TargetInvokationException wrapper, so<br>    // check the InnerException property for expected Exception types.<br>    if (e.Exception.InnerException is NorthwindDataException)<br>    {<br>      Label1.Text = e.Exception.InnerException.Message;<br>      // Because the exception is handled, there is<br>      // no reason to throw it.<br>      e.ExceptionHandled = true;<br>    }<br>  }<br>}<br><br>&lt;/script&gt;<br>&lt;html  &gt;<br>  &lt;head&gt;<br>    &lt;title&gt;ObjectDataSource - C# Example&lt;/title&gt;<br>  &lt;/head&gt;<br>  &lt;body&gt;<br>    &lt;form id=&quot;Form1&quot; method=&quot;post&quot; runat=&quot;server&quot;&gt;<br><br>        &lt;asp:gridview<br>          id=&quot;GridView1&quot;<br>          runat=&quot;server&quot;<br>          datasourceid=&quot;ObjectDataSource1&quot;<br>          autogeneratedeletebutton=&quot;true&quot;<br>          autogeneratecolumns=&quot;false&quot;<br>          datakeynames=&quot;EmpID&quot;&gt;<br>          &lt;columns&gt;<br>            &lt;asp:boundfield headertext=&quot;EmpID&quot; datafield=&quot;EmpID&quot; /&gt;<br>            &lt;asp:boundfield headertext=&quot;First Name&quot; datafield=&quot;FirstName&quot; /&gt;<br>            &lt;asp:boundfield headertext=&quot;Last Name&quot; datafield=&quot;LastName&quot; /&gt;<br>          &lt;/columns&gt;<br>        &lt;/asp:gridview&gt;<br><br>        &lt;asp:objectdatasource<br>          id=&quot;ObjectDataSource1&quot;<br>          runat=&quot;server&quot;<br>          selectmethod=&quot;GetAllEmployees&quot;<br>          deletemethod=&quot;DeleteEmployee&quot;<br>          ondeleting=&quot;NorthwindEmployeeDeleting&quot;<br>          ondeleted=&quot;NorthwindEmployeeDeleted&quot;<br>          typename=&quot;Samples.AspNet.CS.EmployeeLogic&quot;&gt;<br>          &lt;deleteparameters&gt;<br>            &lt;asp:parameter name=&quot;EmpID&quot; type=&quot;Int32&quot; /&gt;<br>          &lt;/deleteparameters&gt;<br>        &lt;/asp:objectdatasource&gt;<br><br>        &lt;asp:label id=&quot;Label1&quot; runat=&quot;server&quot; /&gt;<br><br>    &lt;/form&gt;<br>  &lt;/body&gt;<br>&lt;/html&gt;<br><br><div align=right><a style="text-decoration:none;" href="http://www.cnblogs.com/onlyendure/" target="_blank">大宋提刑官</a> 2008-07-09 13:01 <a href="http://www.cnblogs.com/onlyendure/archive/2008/07/09/1238805.html#1249488#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>re: 静态构造函数（C# 编程指南）</title><link>http://www.cnblogs.com/onlyendure/archive/2008/07/08/1202647.html#1248046</link><dc:creator>大宋提刑官</dc:creator><author>大宋提刑官</author><pubDate>Tue, 08 Jul 2008 01:35:08 GMT</pubDate><guid>http://www.cnblogs.com/onlyendure/archive/2008/07/08/1202647.html#1248046</guid><description><![CDATA[Note one thing here: we are not making any explicit call to the constructor of base class neither by initializer nor by the base keyword, but it is still executing. This is the normal behavior of the constructor.<br><br><br><br><div align=right><a style="text-decoration:none;" href="http://www.cnblogs.com/onlyendure/" target="_blank">大宋提刑官</a> 2008-07-08 09:35 <a href="http://www.cnblogs.com/onlyendure/archive/2008/07/08/1202647.html#1248046#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>re: 静态构造函数（C# 编程指南）</title><link>http://www.cnblogs.com/onlyendure/archive/2008/07/08/1202647.html#1248045</link><dc:creator>大宋提刑官</dc:creator><author>大宋提刑官</author><pubDate>Tue, 08 Jul 2008 01:34:53 GMT</pubDate><guid>http://www.cnblogs.com/onlyendure/archive/2008/07/08/1202647.html#1248045</guid><description><![CDATA[An Intro to Constructors in C#<a href="http://www.codeproject.com/KB/dotnet/ConstructorsInCSharp.aspx" target="_new">http://www.codeproject.com/KB/dotnet/ConstructorsInCSharp.aspx</a><br>public class myBaseClass<br>{<br>    public myBaseClass()<br>    {<br>        // Code for First Base class Constructor<br>    }<br><br>    public myBaseClass(int Age)<br>    {<br>        // Code for Second Base class Constructor<br>    }<br><br>    // Other class members goes here<br>}<br><br>public class myDerivedClass : myBaseClass<br>// Note that I am inheriting the class here.<br>{<br>    public myDerivedClass()<br>    {<br>        // Code for the First myDerivedClass Constructor.<br>    }<br><br>    public myDerivedClass(int Age):base(Age)<br>    {<br>        // Code for the Second myDerivedClass Constructor.<br>    }<br><br>    // Other class members goes here<br>}<br>Now, what will be the execution sequence here:<br><br>If I create the object of the derived class as:<br><br>myDerivedClass obj = new myDerivedClass()<br>Then the sequence of execution will be:<br><br>public myBaseClass() method. <br>and then public myDerivedClass() method. <br><br><br><div align=right><a style="text-decoration:none;" href="http://www.cnblogs.com/onlyendure/" target="_blank">大宋提刑官</a> 2008-07-08 09:34 <a href="http://www.cnblogs.com/onlyendure/archive/2008/07/08/1202647.html#1248045#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>re: SortedList Class[MSDN]</title><link>http://www.cnblogs.com/onlyendure/archive/2008/06/28/1194846.html#1238834</link><dc:creator>大宋提刑官</dc:creator><author>大宋提刑官</author><pubDate>Sat, 28 Jun 2008 02:13:52 GMT</pubDate><guid>http://www.cnblogs.com/onlyendure/archive/2008/06/28/1194846.html#1238834</guid><description><![CDATA[using System;<br><br>public interface IComparable<br>{<br>    int CompareTo(IComparable comp);<br>}<br><br>class Person : IComparable<br>{<br>    private string name;<br>    private int age;<br><br>    public Person() : this(&quot;&quot;, 0) { }<br>    public Person(string name) : this(name, 0) { }<br>    public Person(string name, int age)<br>    {<br>        this.name = name;<br>        this.age = age;<br>    }<br><br>    public string Name<br>    {<br>        get { return this.name; }<br>    }<br><br>    public int Age<br>    {<br>        get { return this.age; }<br>    }<br><br>    #region IComparable 成员<br><br>    public virtual int CompareTo(IComparable comp)<br>    {<br>        Person temp = (Person)comp;<br><br>        if (this.age &gt; temp.age)<br>            return 1;<br>        else if (this.age == temp.age)<br>            return 0;<br>        else<br>            return -1;<br>    }<br><br>    #endregion<br>}<br><br>class BubbleSorter<br>{<br>    private BubbleSorter() { }<br><br>    public static void BubbleSortAscending(IComparable[] arr)<br>    {<br>        for (int i = 1; i &lt; arr.Length; i++)<br>        {<br>            for (int j = 0; j &lt; arr.Length - i; j++)<br>            {<br>                if (arr[j].CompareTo(arr[j + 1]) &gt; 0)<br>                {<br>                    IComparable temp;<br>                    temp = arr[j];<br>                    arr[j] = arr[j + 1];<br>                    arr[j + 1] = temp;<br>                }<br>            }<br>        }<br>    }<br>}<br><br>class PersonBubbleTest<br>{<br>    static void Main(string[] args)<br>    {<br>        Person[] p = new Person[4];<br><br>        p[0] = new Person(&quot;aa&quot;, 29);<br>        p[1] = new Person(&quot;bb&quot;, 30);<br>        p[2] = new Person(&quot;cc&quot;, 21);<br>        p[3] = new Person(&quot;dd&quot;, 19);<br><br>        BubbleSorter.BubbleSortAscending(p);<br><br>        foreach (Person temp in p)<br>        {<br>            Console.WriteLine(&quot;Name: {0}, Age: {1}&quot;, temp.Name, temp.Age);<br>        }<br>    }<br>}<br><br><div align=right><a style="text-decoration:none;" href="http://www.cnblogs.com/onlyendure/" target="_blank">大宋提刑官</a> 2008-06-28 10:13 <a href="http://www.cnblogs.com/onlyendure/archive/2008/06/28/1194846.html#1238834#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>re: SortedList Class[MSDN]</title><link>http://www.cnblogs.com/onlyendure/archive/2008/06/28/1194846.html#1238832</link><dc:creator>大宋提刑官</dc:creator><author>大宋提刑官</author><pubDate>Sat, 28 Jun 2008 02:13:33 GMT</pubDate><guid>http://www.cnblogs.com/onlyendure/archive/2008/06/28/1194846.html#1238832</guid><description><![CDATA[Sortedlist 本来就是按键排序的键值对集合，不能按楼主所说的Value来排序 <br><br>如果要实现楼主实现的功能，楼主必须自己写一个实现IComparable接口的类 <br><br><br><div align=right><a style="text-decoration:none;" href="http://www.cnblogs.com/onlyendure/" target="_blank">大宋提刑官</a> 2008-06-28 10:13 <a href="http://www.cnblogs.com/onlyendure/archive/2008/06/28/1194846.html#1238832#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>re: ASP.NET实现在线截图[转载]</title><link>http://www.cnblogs.com/onlyendure/archive/2008/06/27/1155473.html#1238206</link><dc:creator>花逢春</dc:creator><author>花逢春</author><pubDate>Fri, 27 Jun 2008 05:54:59 GMT</pubDate><guid>http://www.cnblogs.com/onlyendure/archive/2008/06/27/1155473.html#1238206</guid><description><![CDATA[怎么没提供JS下载?请传份给我,可以吗?<br><br><div align=right><a style="text-decoration:none;" href="http://www.cnblogs.com/onlyendure/" target="_blank">花逢春</a> 2008-06-27 13:54 <a href="http://www.cnblogs.com/onlyendure/archive/2008/06/27/1155473.html#1238206#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>re: ASP.NET实现在线截图[转载]</title><link>http://www.cnblogs.com/onlyendure/archive/2008/06/27/1155473.html#1237861</link><dc:creator>zjysky</dc:creator><author>zjysky</author><pubDate>Fri, 27 Jun 2008 01:33:32 GMT</pubDate><guid>http://www.cnblogs.com/onlyendure/archive/2008/06/27/1155473.html#1237861</guid><description><![CDATA[哈哈。你转载我的文章。<br><br><div align=right><a style="text-decoration:none;" href="http://www.cnblogs.com/onlyendure/" target="_blank">zjysky</a> 2008-06-27 09:33 <a href="http://www.cnblogs.com/onlyendure/archive/2008/06/27/1155473.html#1237861#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>re: ASP.NET实现在线截图[转载]</title><link>http://www.cnblogs.com/onlyendure/archive/2008/06/25/1155473.html#1235230</link><dc:creator>骆明亮</dc:creator><author>骆明亮</author><pubDate>Tue, 24 Jun 2008 18:23:24 GMT</pubDate><guid>http://www.cnblogs.com/onlyendure/archive/2008/06/25/1155473.html#1235230</guid><description><![CDATA[研究了半天 实现不了<br><br><div align=right><a style="text-decoration:none;" href="http://www.cnblogs.com/onlyendure/" target="_blank">骆明亮</a> 2008-06-25 02:23 <a href="http://www.cnblogs.com/onlyendure/archive/2008/06/25/1155473.html#1235230#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>re: ASP.NET实现在线截图[转载]</title><link>http://www.cnblogs.com/onlyendure/archive/2008/06/24/1155473.html#1235141</link><dc:creator>骆明亮</dc:creator><author>骆明亮</author><pubDate>Tue, 24 Jun 2008 15:15:10 GMT</pubDate><guid>http://www.cnblogs.com/onlyendure/archive/2008/06/24/1155473.html#1235141</guid><description><![CDATA[给我一份好吗？<br><br><div align=right><a style="text-decoration:none;" href="http://www.cnblogs.com/onlyendure/" target="_blank">骆明亮</a> 2008-06-24 23:15 <a href="http://www.cnblogs.com/onlyendure/archive/2008/06/24/1155473.html#1235141#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item></channel></rss>