Monday, January 6, 2014

ItemUpdating event only when metadata/properties are changed

1:  if (properties.AfterProperties["vti_sourcecontrolcheckedoutby"] == null && properties.BeforeProperties["vti_sourcecontrolcheckedoutby"] != null)
  
2:  {
  
3:  //This is when the update event is triggered by check-in.
  
4:  }
  
5:  else{
  
6:  //This is triggered by events other than check-in action.
  
7:  if (Convert.ToInt32(properties.AfterProperties["vti_filesize"]) == 0)
  
8:  {
  
9:  }
  
10:  }
  

No comments:

Post a Comment