I've an event receiver and in itemupating i check if i've a value for a lookup field but get an exception. If i look in powershell, the column exist so the first if is ok but he can't test if it's null. I've tried to replace the space by x0020 with no more success this line is working but doesn't get the value: properties.ListItem.Fields["Service box"]
if (properties.ListItem.Fields.ContainsField("Service box"))
{
//here is throw the exception
if (properties.ListItem["Service box"] != null)
{
serviceOld = properties.ListItem["Service box"].ToString();
}
}
I follow this next post without success: http://blog.vanmeeuwen-online.nl/2012/07/value-does-not-fall-within-expected.html
thanks