Custom Search Scopes at Site Collection Level
static void GetAvailableScopes() { SearchContext searchContext; using ( SPSite site = new SPSite ( "Your Site Collection URL" )) { searchContext = SearchContext .GetContext(site); Scopes scopes = new Scopes (searchContext); foreach ( Scope scope in scopes.AllScopes) { ...