This is the event which occurs before the Item is added.
SPContext.Current is null for some reason and hence its kind of a dead end to go towards this path.
A non obvious way to achieve this is by using the following code snippet.
public override void ItemAdding(SPItemEventProperties properties)
{
SPUser user = properties.OpenWeb().AllUsers.GetByID(properties.CurrentUserId)
}
~Abhishek
No comments:
Post a Comment