Anonymous method question


i thought understood topic of anonymous methods, until saw , cannot reconcile type of programming.  code in statement block appears attached declaration line above it. anonymous method delegate understood? can't a statement block lines end comma , not semicolon. i hate sound dumb, got know is:

public string url { get; set; }

public string schemaurl { get; set; }

helper abc = new helper(){this.url,

schemaurl =

this.schemaurl

};

url =

basically not anonymous method way instantiate class in 1 line.

using system; using system.collections.generic; using system.linq; using system.text;  namespace consoleapplication1 {     class program     {         static void main(string[] args)         {             helper helper = new helper { schemaurl = "dhjjjty787", url = "www.yahoo.com" };         }     } }   public class helper {     public string url { get; set; }     public string schemaurl { get; set; } }    


john grove, senior software engineer http://www.digitizedschematic.com/




Visual Studio Languages  ,  .NET Framework  >  Visual C#



Comments

Popular posts from this blog

Azure DocumentDB Owner resource does not exist

job syspolicy_purge_history job fail in sqlserver 2008

Trying to register with public marketplace error with 'Get-AzureStackStampInformation'