API Questions on Kentico API.
Version 6.x > API > SetObject() inaccessible due to protection level - adding CMS.TreeEngine.DocumentAliasInfo View modes: 
User avatar
Member
Member
Andy - 11/30/2011 1:36:11 PM
   
SetObject() inaccessible due to protection level - adding CMS.TreeEngine.DocumentAliasInfo
Hi - the code here
http://devnet.kentico.com/Knowledge-Base/API-and-Internals/How-to-create-a-new-document-alias-using-API.aspx does not appear to work anymore.
specifically the line
aliasinfo.SetObject();

references a [now] inaccessible method.
What's the best approach in 6? Or am I just missing something obvious?
Thanks

User avatar
Member
Member
Andy - 12/2/2011 11:19:14 AM
   
RE:SetObject() inaccessible due to protection level - adding CMS.TreeEngine.DocumentAliasInfo
Anyone any thoughts? The sample code won't compile anymore... and I am kind of under a deadline. Even rough pointers of things to try would help.
Thanks
Andy

User avatar
Member
Member
kentico_michal - 12/4/2011 10:02:01 PM
   
RE:SetObject() inaccessible due to protection level - adding CMS.TreeEngine.DocumentAliasInfo
Hello,

Could you please try to use the following method instead (CMS.TreeEngine.DocumentAliasInfoProvider class):
public static void SetDocumentAliasInfo(
DocumentAliasInfo documentAlias,
string siteName
)

Best regards,
Michal Legen