Hi,
We were getting the following error that “list doesn’t exist in the site” because the user was not having read permission on that list.
The code we were using was
SPList myList= spWeb.Lists[“mylist”];
A better approach would be
SPList myList = spWeb.Lists.TryGetList(“myList”);
If(myList != null )
// …
Bye ..
Discover more from Nishant Rana's Weblog
Subscribe to get the latest posts sent to your email.
