We have implemneted a bulk site creation tool and in that i am wondering how can we set access request progrmatically for the whole site collection . i know that we can set the request access for individual groups and i am able to implement it with following code .But i wnat to implement the same funcationality at the site collection level.Can some one please help me ..
My code for groups access
SPGroup adminGroup = web.SiteGroups[groupName];
adminGroup.Owner = adminGroup;
adminGroup.AllowRequestToJoinLeave = true;
PickerEntity pe = (PickerEntity)pickContact.ResolvedEntities[0];
string email1 = pe.Description;
adminGroup.RequestToJoinLeaveEmailSetting = email1 + "@domain.org";
adminGroup.Update();
Thanks