I think you have to do 2 things:
1. instantiate the portal NOT from Context, but like
SPSite portal = new SPSite("http://...");
(you can also use SPControl.Site.HostName and Site.Port etc)
2. impersonate as yourself before you do your action. If that doesnt work, try as admin. There are...
For Sharepoint 2003 (SP2) I wrote an eventhandler wich assigns an unique number to a document when the INSERT event fires.
To avoid locking exceptions, the code loops until the file is no longer locked. Otherwise the document doesnt get a number.
This works OK, until someone locks a file...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.