none
Searching using search object model RRS feed

  • Question

  •  Hi,
    i m using search object model to search in a site collection

    SPSite site = new SPSite("http://servername:portno/default.aspx");

    KeywordQuery kwq = new KeywordQuery(site);

    i hv two sub site under dat site collection
    Can ny one plz tell me how to search in a subsite using search object model.
    bcoz if i give the link of subsite in the keyword query den also it is searching on the whole site collection
    nt on dat particular site

    Thanks in advance

    Friday, August 22, 2008 6:33 AM

All replies

  • You can use property filter with your search query text. For examle:
    site:"http://sitename" keyword



    -Sridhar http://sridharu.blogspot.com
    Friday, August 22, 2008 9:06 AM
  • is dere no way to search on the subsite
    using search object model
    Friday, August 22, 2008 9:10 AM