Content Server 2010
Hi All,
Has anyone had any experience of having to handle reserve characters in category search terms.
I have a web service category search, based on a string attribute, where sometimes there are characters withing bracket characters '(' and ')'.
At the moment the following search lines are breaking on them.
The standard search line would be something like
string csSearchString = "lookfor1=complexquery&within1=metadata&where1=(( Attr_12345 : " refno + "))" ;
And according to the Livelink API search guide, you should encode the term into it's UTF8 hex equiv for Content Server 2010 i.e.
string csSearchString = "lookfor1=complexquery&within1=metadata&where1=(( Attr_12345 : " + refno.Replace( "(" , "%28" ).Replace( ")" , "%29" ) + "))" ;
but this then doesn't match any documents correctly (this is a equals search time exactly type search).
Have also tried the native c# UrlEncode methods also but no joy.
Any ideas of how to safely pass the search term accross into the search string when it contains '(' and ')'
cheers
John