Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Value does not fall within the expected range

5 views
Skip to first unread message

sumbhav

unread,
Dec 29, 2008, 11:47:31 AM12/29/08
to
Hi,

I am having problem accessing any sites under /SiteDirectory. It was
working fine but suddenly it started throwing following error when I
try to access any site under /SiteDirectory.:

[ArgumentException: Value does not fall within the expected range.]

Microsoft.SharePoint.Library.SPRequestInternalClass.GetFileAndMetaInfo
(String bstrUrl, Byte bPageView, Byte bPageMode, Byte
bGetBuildDependencySet, String bstrCurrentFolderUrl, Boolean&
pbCanCustomizePages, Boolean& pbCanPersonalizeWebParts, Boolean&
pbCanAddDeleteWebParts, Boolean& pbGhostedDocument, Boolean&
pbDefaultToPersonal, String& pbstrSiteRoot, Guid& pgSiteId, UInt32&
pdwVersion, String& pbstrTimeLastModified, String& pbstrContent, Byte&
pVerGhostedSetupPath, UInt32& pdwPartCount, Object& pvarMetaData,
Object& pvarMultipleMeetingDoclibRootFolders, String&
pbstrRedirectUrl, Boolean& pbObjectIsList, Guid& pgListId, UInt32&
pdwItemId, Int64& pllListFlags, Boolean& pbAccessDenied, Guid&
pgDocId, Byte& piLevel, UInt64& ppermMask, Object&
pvarBuildDependencySet, UInt32& pdwNumBuildDependencies, Object&
pvarBuildDependencies, String& pbstrFolderUrl, String&
pbstrContentTypeOrder) +0
Microsoft.SharePoint.Library.SPRequest.GetFileAndMetaInfo(String
bstrUrl, Byte bPageView, Byte bPageMode, Byte bGetBuildDependencySet,
String bstrCurrentFolderUrl, Boolean& pbCanCustomizePages, Boolean&
pbCanPersonalizeWebParts, Boolean& pbCanAddDeleteWebParts, Boolean&
pbGhostedDocument, Boolean& pbDefaultToPersonal, String&
pbstrSiteRoot, Guid& pgSiteId, UInt32& pdwVersion, String&
pbstrTimeLastModified, String& pbstrContent, Byte&
pVerGhostedSetupPath, UInt32& pdwPartCount, Object& pvarMetaData,
Object& pvarMultipleMeetingDoclibRootFolders, String&
pbstrRedirectUrl, Boolean& pbObjectIsList, Guid& pgListId, UInt32&
pdwItemId, Int64& pllListFlags, Boolean& pbAccessDenied, Guid&
pgDocId, Byte& piLevel, UInt64& ppermMask, Object&
pvarBuildDependencySet, UInt32& pdwNumBuildDependencies, Object&
pvarBuildDependencies, String& pbstrFolderUrl, String&
pbstrContentTypeOrder) +215
Microsoft.SharePoint.SPWeb.GetWebPartPageContent(Uri pageUrl,
PageView requestedView, HttpContext context, Boolean forRender,
Boolean includeHidden, Boolean mainFileRequest, Boolean
fetchDependencyInformation, Boolean& ghostedPage, Byte&
verGhostedPage, String& siteRoot, Guid& siteId, Int64& bytes, Guid&
docId, UInt32& docVersion, String& timeLastModified, Byte& level,
Object& buildDependencySetData, UInt32& dependencyCount, Object&
buildDependencies, SPWebPartCollectionInitialState& initialState,
Object& oMultipleMeetingDoclibRootFolders, String& redirectUrl,
Boolean& ObjectIsList, Guid& listId) +1552

Microsoft.SharePoint.ApplicationRuntime.SPRequestModuleData.FetchWebPartPageInformationForInit
(HttpContext context, SPWeb spweb, Boolean mainFileRequest, String
path, Boolean impersonate, Boolean& fGhostedPage, Byte&
verGhostedPage, Guid& docId, UInt32& docVersion, String&
timeLastModified, SPFileLevel& spLevel, String& masterPageUrl, String&
customMasterPageUrl, String& webUrl, String& siteUrl, Guid& siteId,
Object& buildDependencySetData, SPWebPartCollectionInitialState&
initialState, String& siteRoot, String& redirectUrl, Object&
oMultipleMeetingDoclibRootFolders, Boolean& objectIsList, Guid&
listId, Int64& bytes) +692

Microsoft.SharePoint.ApplicationRuntime.SPRequestModuleData.GetFileForRequest
(HttpContext context, SPWeb web, Boolean exclusion, String
virtualPath) +209

Microsoft.SharePoint.ApplicationRuntime.SPRequestModule.InitContextWeb
(HttpContext context, SPWeb web) +79
Microsoft.SharePoint.WebControls.SPControl.SPWebEnsureSPControl
(HttpContext context) +335
Microsoft.SharePoint.WebControls.SPControl.GetContextWeb
(HttpContext context) +25

Microsoft.SharePoint.ApplicationRuntime.SPRequestModule.PostResolveRequestCacheHandler
(Object oSender, EventArgs ea) +322

System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute
() +92
System.Web.HttpApplication.ExecuteStep(IExecutionStep step,
Boolean& completedSynchronously) +64


I would really appreciate any help to resolve this issue.

Regards,
Sumit

Xopher...@gmail.com

unread,
Dec 31, 2008, 2:29:53 PM12/31/08
to
I worked with the site directory about a year ago.
Here is some of the code I used:

SPWeb web = SPContext.Current.Site.AllWebs["SiteDirectory/"];
SPList list = web.Lists["Sites"];
SPQuery q = new SPQuery();
q.ViewFields = "<FieldRef Name='Title'/><FieldRef Name='OrgCode'/
><FieldRef Name='ParentNode'/><FieldRef Name='URL'/>";
q.Query = "<Where><And><Eq><FieldRef Name='SiteType'/><Value
Type='Text'>Organization</Value></Eq><Eq><FieldRef Name='RegionMulti'/
><Value Type='Text'>Internal</Value></Eq></And></
Where><OrderBy><FieldRef Name ='OrgCode' Ascending='TRUE'/></
OrderBy>";
SPListItemCollection iList = list.GetItems(q);

Then I checked each value before use to make sure it wasn't null.

Can I see you code?

brandysoft

unread,
Feb 17, 2009, 5:26:58 AM2/17/09
to
Use Sharepoint Form Validation and see whether it can help you or
not.

quang

unread,
Apr 8, 2009, 1:39:05 AM4/8/09
to
On Feb 17, 6:26 pm, brandysoft <sharepoint...@gmail.com> wrote:
> Use Sharepoint Form Validation and see whether it can help you or
> not.

did you do anything to the layout of your site if so you better fix
it.

This site have solve my problem. It talks about different url due to
layout changes.

<a href="http://connectionstringexamples.com/article.php?
story=Sharepoint-error-System-Argument">http://
connectionstringexamples.com/article.php?story=Sharepoint-error-System-
Argument</a>

sreevan

unread,
Oct 20, 2009, 5:38:20 PM10/20/09
to
Were you able to fix this issue. We are seeing errors when accessing any sites under /SitesDirectory.

Thanks,
Sree

sumbhav wrote:

Value does not fall within the expected range

30-Dec-08

Hi,

I am having problem accessing any sites under /SiteDirectory. It was
working fine but suddenly it started throwing following error when I
try to access any site under /SiteDirectory.:

[Argumen

Previous Posts In This Thread:

On Tuesday, December 30, 2008 6:28 AM
sumbhav wrote:

Value does not fall within the expected range

Hi,

I am having problem accessing any sites under /SiteDirectory. It was
working fine but suddenly it started throwing following error when I
try to access any site under /SiteDirectory.:

[Argumen

On Friday, January 09, 2009 7:25 AM
XopherDesig wrote:

I worked with the site directory about a year ago.
I worked with the site directory about a year ago.
Here is some of the code I used:

SPWeb web = SPContext.Current.Site.AllWebs["SiteDirectory/"];
SPList list = web.Lists["Sites"];
SPQuery q = new SPQ

On Thursday, February 19, 2009 7:22 AM
brandysoft wrote:

Use Sharepoint Form Validation and see whether it can help you ornot.
Use Sharepoint Form Validation and see whether it can help you or
not.

On Saturday, April 11, 2009 6:09 PM
quang wrote:

Re: Value does not fall within the expected range


did you do anything to the layout of your site if so you better fix
it.

This site have solve my problem. It talks about different url due to
layout changes.

<a href=3D"http://connectionstringexample

EggHeadCafe - Software Developer Portal of Choice
Creating an Object Configuration Section in .Net 2.0
http://www.eggheadcafe.com/tutorials/aspnet/5082a79d-9733-45a2-827d-3fbe41b5ce79/creating-an-object-config.aspx

0 new messages