| Stefan [MSFT] 2004-07-28, 6:10 pm |
| Hi Randall,
sorry never seen.
The error message seems not to be the whole message.
Could you post the complete error message content?
Thanks,
Stefan.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
MCMS FAQ:
http://download.microsoft.com/downl...6a/MCMS+2002+-+(complete)+FAQ.htm
MCMS Blog: http://blogs.msdn.com/stefan_gossner/category/4983.aspx
MCMS Sample Code:
http://www.gotdotnet.com/community/...t+S
erver
MCMS Whitepapers and other docs:
http://blogs.msdn.com/stefan_gossne...2/07/41859.aspx
--------------------------------
"Randall" <Randall@discussions.microsoft.com> wrote in message
news:1E3D4449-4044-4C31-820D-8B835DC54893@microsoft.com...
> Hi all,
>
> I have written a code which expires and moves the posting to another
channel .
> Some times I get this error.
> =========
> System.Runtime.InteropServices.COMException: Server error. Contact the
site administrator.
>
> Source Error:
>
>
> Line 145: CmsApplicationContext AppContext = new CmsApplicationContext();
> Line 146: AppContext.AuthenticateAsCurrentUser( PublishingMode.Update );
> Line 147: Posting p
=AppContext.Searches.GetByGuid(arrPosting[i].ToString()) as Posting ;
>
> ============
> The complete code is as follows:
>
> CmsApplicationContext AppContext = new CmsApplicationContext();
> AppContext.AuthenticateAsCurrentUser( PublishingMode.Update );
> Posting p =AppContext.Searches.GetByGuid(arrPosting[i].ToString()) as
Posting ;
> p.ExpiryDate=CmsHttpContext.Current.ServerTime.ToLocalTime();
> p.MoveTo(pDesChannel);
> AppContext.CommitAll();
> AppContext.Dispose();
>
> Where arrPostring[i] contains the Guid of posting.
> Are you aware of this problem and error. What does it mean?
>
> I appreciate your help.
>
> Regards,
> Randall
>
> Line 148: Response.Write(p.Name);
> Line 149: Response.End();
>
> ====================
|