Vitor's profileIT ChroniclesPhotosBlogLists Tools Help

IT Chronicles

Erratic adventures in IT dimensions
April 21

The Title field trap

Yesterday I had an argument exception ("value does not fall within the expected range") within my code. I was submiting some data from a form to a SharePoint custom list when this happened. Debugging the application showed me that the exception was at the line with the expression item[field_name] = value.
 
I thought "how does this not fall into the expected range?! The field type is text and I'm using a string value for Christ sake!". After a short checking and reflection I thought "Well... maybe it's the name of the field..." and so I checked it. Nope! The name was alright. The column name was "Name" and it was alright!
 
So I went around and around trying to solve it: web, colleagues,... and suddenly something hit me (not literally). "Wait! I changed the name of the field! The original name is Title!". I changed the name in the item[field_name] and everything started working correctly.
 
I know this situation may be a lame one, but I think it can help someone with a similar problem. At least is another post about this issue. : )
 
All the best and good coding!
April 20

SPDataSource

Another simple and great article. Check it out.

Understanding the 'using' statement in C#

I found in CodeProject this excellent article about the 'using' keyword in C#. Enjoy.
April 16

Best practices for coding

Back again!
 
I just have read an article about coding best practices that I found really interesting and want to share with you. It is just the first part, but very interesting all the same. Click here to read it.
 
All the best
October 29

Visual Studio Team System 2010 Overview

 

The new version of VS Team System comes with some powerful goodies. Here are a few features:

  • individuals can create visual representations of existing code assets;
  • code validation against a visual representation of the architecture;
  • testers can follow a set of defined validation steps and create actionable bugs;
  • identification of the tests that should be run to validate code changes.

To know more, just click here.

 

Vitor Castelo

Occupation
Location
View Vitor Castelo's profile on LinkedIn  Spread the Recycling Message
Photo 1 of 1

Video

No content has been added yet.