Microsoft Content Management Server - Getting Channel's Display Name using channel's path

This is Interesting: Free IT Magazines  
Home > Archive > Microsoft Content Management Server > May 2004 > Getting Channel's Display Name using channel's path





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Getting Channel's Display Name using channel's path
Trevor Grant

2004-05-24, 7:34 am

Hi

Try something like this:

string displayName = "";

CmsHttpContext cmsContext = CmsHttpContext.Current;
Channel c = cmsContext.Searches.GetByPath
("/Channels/mySite/aboutUs") as Channel;
if(c!=null)
{
displayName = c.DisplayName;
}

Trevor

>-----Original Message-----
>Hi,
>
>Is there any way where I can get a channel's display name
>with just the path?
>
>'Cause I would like to programmically include a hyperlink
>on Page Load.
>But I only have the path (/Channels/mySite/aboutUs).
>And I would like to use the Display Name of that channel
>as the name of the link.
>
>Thanks in advance.
>
>Regards,
>George
>.
>

Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com