long maximumBytesForSiteCollection;
maximumBytesForSiteCollection = Convert.ToInt32(ddlQuota.SelectedValue.Split(' ')[0]) * 1024 * 1024;
SPSite _newsc = new SPSite(newSiteCollURL);
SPQuota quota = _newsc.Quota;
quota.StorageMaximumLevel = Convert.ToInt32(ddlQuota.SelectedValue.Split(' ')[0]) * 1024 * 1024;
quota.StorageWarningLevel = (long)(0.75 * Convert.ToInt32(ddlQuota.SelectedValue.Split(' ')[0]) * 1024 * 1024);
_newsc.Quota = quota;
sharepoint is throwing the error at "quota.StorageMaximumLevel = Convert.ToInt32(ddlQuota.SelectedValue.Split(' ')[0]) * 1024 * 1024;" line.
what exactly i was doing here is.. creating a site colelction programmatically and assigning quota to newly created sitecollection.
i was able to create the sitecollection properly butwhile assigning the quota, this is the error message i am getting.
i couldn't figure out exactly what this means.
Thanks
Bob