i




 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Convert code C# 2008 to code C# 2005 ?
02-25-2015, 08:42 AM
Post: #1
Not Solved Convert code C# 2008 to code C# 2005 ?
I want convert code C# 2008 to code C# 2005, I did not understand the command C# 2008 to switch to C# 2005, see below is the error code can solve the error command do ? run the code in C# 2008 very good


Code:
private void textBox1_TextChanged(object sender, EventArgs e)
        {
            string str = textBox1.Text.Trim();


            if (!string.IsNullOrEmpty(str))
            {
                // Error in here
                Expression<Func<CustomData, bool>> expr = n => GetCondition(n, str);
                this.gridControl1.DataSource = this.lstCustomData.Where<CustomData>(expr.Compile()).ToList();
            }
            else
                this.gridControl1.DataSource = this.lstCustomData;
            this.gridControl1.RefreshDataSource();
        }


public class CustomData
    {
        // Error in here
        public int col1 { get; set; }
        public string col2 { get; set; }
        public string col3 { get; set; }
        public int col4 { get; set; }
    }



Quote


Possibly Related Threads...
Thread: Author Replies Views: Last Post
  How the convert the code below form C#2008 to C#2005 have got Dictionary? dongtrien 2 1,571 03-24-2015 09:56 AM
Last Post: dongtrien
  Getting problem when trying to connect to sql from the code Mercy_777 2 1,209 02-11-2015 09:12 AM
Last Post: Chandra_NVS
  CommandBuilder Code Ismail2012 0 895 09-25-2013 09:50 PM
Last Post: Ismail2012
  feedback form -->sending an email in ASP.net using C# code rcsp 1 1,395 08-27-2013 09:56 AM
Last Post: magnum_2007
  GridView code understanding kbsrinivas.07@gmail.com 1 1,013 06-26-2013 08:15 AM
Last Post: magnum_2007



User(s) browsing this thread: 1 Guest(s)