Backup Utility Error Message

Topics: Developer Forum
Sep 14, 2008 at 7:56 AM
Edited Sep 14, 2008 at 8:16 AM

Hi, I'm trying to get the Backup utility working and have the following error message:

System.Security.SecurityException: That assembly does not allow partially trusted callers. at System.Security.CodeAccessSecurityEngine.ThrowSecurityException(Assembly asm, PermissionSet granted, PermissionSet refused, RuntimeMethodHandle rmh, SecurityAction action, Object demand, IPermission permThatFailed) at Administration_Backup.ZipIt(String Path, String outPathAndZipFile, String password) at Administration_Backup.backupData() in d:\hosting\tailwags\Administration\Backup.aspx.cs:line 162 The action that failed was: LinkDemand The Zone of the assembly that failed was: MyComputer

In the Web.sitemap, I placed this code:

<siteMapNode url="~/administration/Backup.aspx" VisibleInMenu="True" title="Backup" />

Instead of this:

xml.Append("      <siteMapNode url=\"~/administration/Backup.aspx\" VisibleInMenu=\"True\" title=\"" + Resources.StringsRes.cls_Backup + "\"/>");

Any ideas what's going wrong, and as far as the line of code, what is the exact coe that needs to go in the Web.sitemap file, is it?

<siteMapNode url=\"~/administration/Backup.aspx\" VisibleInMenu=\"True\" title=\"" + Resources.StringsRes.cls_Backup + "\"/>

Which I tried but doesn't work either. Perhaps a variation on it?

Regards
Ron