|
Home > Archive > Microsoft Content Management Server > March 2004 > Re: Customising the Sharepoint Search connector for CMS
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 |
Re: Customising the Sharepoint Search connector for CMS
|
|
| Stefan [MSFT] 2004-03-29, 12:45 pm |
| Hi David,
it is not possible to customize the control.
What you could do is to create a custom control derived from this control
and overload the Render method.
Here you are able to consume the response stream of the parent and could
parse and modify it.
Cheers,
Stefan.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"David" <anonymous@discussions.microsoft.com> wrote in message
news:11681F10-71AE-41AD-9C66-8D28C0EFB475@microsoft.com...
> Hi,
> I was wondering if anyone knew how to customise the SearchResultsControl
in the CMS Connector for sharepoint. It displays a 'last edited by' column
that we do not want to be visible to the public (since this is a public
site).
>
> Any help would be appreciated - I don't want to have to write this control
from scratch!
>
> Regards,
> David
| |
| David 2004-03-29, 12:47 pm |
| Thanks Stephan,
....is the source code available - or some equivalent sample code? This would make it easy to modify.
David
| |
| Stefan [MSFT] 2004-03-29, 1:42 pm |
| Hi David,
yes there is "similar" code that shows how to override the render method of
a placeholder control.
So if you only need a starter for this part of the problem, check out this
code:
protected override void Render(System.Web.UI.HtmlTextWriter output)
{
TextWriter tempWriter = new StringWriter();
base.Render(new System.Web.UI.HtmlTextWriter(tempWriter));
string orightml= tempWriter.ToString();
string newhtml = ModifyTheHtmlStream(orightml);
output.Write(newhtml);
}
Cheers,
Stefan.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"David" <anonymous@discussions.microsoft.com> wrote in message
news:3BC70481-D4C9-4186-B09A-4CE26F70D25F@microsoft.com...
> Thanks Stephan,
> ...is the source code available - or some equivalent sample code? This
would make it easy to modify.
>
> David
| |
|
| Stefan,
That's funny! I was thinking more along the lines of code that shows how to query the Sharepoint server and return the search results ;)
I don't really like the idea of parsing HTML strings!
David
|
|
|
|
|