| Author |
Searches.NewPostings()
|
|
|
| I have my Searches.NewPostings() working.
However I need to show all new Postings below a certain channel and in
the subchannels.
I am using this in an if statement:
if(.......&& posting.Path.ToLower().StartsWith("/channels/channelname")
it is only searching channelname for new postings and not going into
any subchannel.
How do I get around this? txs
| |
| Stefan Goßner [MSFT] 2007-01-19, 7:19 am |
| Hi Sonya,
not sure what you mean.
Does the collection you are iterating through contains postings of the
subchannel?
Cheers,
Stefan
"sc" <sonyacooley@vodafone.ie> wrote in message
news:1169206918.048274.222910@51g2000cwl.googlegroups.com...
>I have my Searches.NewPostings() working.
>
> However I need to show all new Postings below a certain channel and in
> the subchannels.
> I am using this in an if statement:
>
> if(.......&& posting.Path.ToLower().StartsWith("/channels/channelname")
>
> it is only searching channelname for new postings and not going into
> any subchannel.
>
> How do I get around this? txs
>
| |
|
| Hi Stefan
This line searches the entire MCMS repository for new Postings.
PostingCollection groupofPostings = cmsContext.Searches.NewPostings(1);
But I have channel below the root channel as a seperate website:[vbcol=seagreen]
I need to return the new Postings from ONLY SubChannelA AND ALL
channels below SubChannelA
I have an if statement that says:
if(posting.StartDate >= DateTime.Now.Subtract(subtractDays)&&
NumberOfLinks > intCounter &&
posting.Path.StartsWith("/Channels/SubChannelA"))
but this is only returning new Postings in the root of SubChannelA and
not any of its subchannels.
| |
| Stefan Goßner [MSFT] 2007-01-19, 1:16 pm |
| Hi SC,
then something seems to be wrong in your string operation.
Sorry but this is not a MCMS related question.
Cheers,
Stefan
"sc" <sonyacooley@vodafone.ie> wrote in message
news:1169209973.191907.301250@s34g2000cwa.googlegroups.com...
> Hi Stefan
>
> This line searches the entire MCMS repository for new Postings.
> PostingCollection groupofPostings = cmsContext.Searches.NewPostings(1);
>
> But I have channel below the root channel as a seperate website:
>
> I need to return the new Postings from ONLY SubChannelA AND ALL
> channels below SubChannelA
>
> I have an if statement that says:
> if(posting.StartDate >= DateTime.Now.Subtract(subtractDays)&&
> NumberOfLinks > intCounter &&
> posting.Path.StartsWith("/Channels/SubChannelA"))
>
> but this is only returning new Postings in the root of SubChannelA and
> not any of its subchannels.
>
|
|
|
|