Click here to Skip to main content
15,881,812 members

Comments by Jon Artus (Top 3 by date)

Jon Artus 27-Apr-12 18:31pm View    
Reason for my vote of 1
Sorry, but this is completely unhelpful. The code is out of context, full of typographical errors ("proider", "inveltory", ".Tex=") and would never compile.

You're not explaining what you're doing, and that the query you're using map to worksheet and column names in a specific workbook in a specific location.
Jon Artus 26-Mar-12 10:41am View    
Reason for my vote of 2
Interesting, but given that collection initializer syntax does this already and will perform better, I'm not sure when I'd ever use this code. You can achieve the same effect by doing:

var dict = new Dictionary<string, object="">
{
{ "Id", 1 },
{ "Name", "Tom Bombadil" },
{ "CreatedOn", DateTime.Today },
{ "CreatedBy", "root" }
};
Jon Artus 26-Mar-12 10:39am View    
Deleted
Reason for my vote of 2
I'm just not clear on what advantage this has over using collection initializer syntax? Given that this does the same thing, but performs better and is easier to read, I'm not sure when I'd ever use that code.

var bag = new Dictionary<string, object="">
{
{ "Id", 1 },
{ "Name", "Tom Bombadil" },
{ "CreatedOn", DateTime.Today },
{ "CreatedBy", "root" }
};