This is one of the exception regularly comes when we do custom development and create custom aspx pages. Everything works fine and no code issues but still this exception comes. I worked hard to fix this problem so long time. Tracked everything like logs, event viewer and more tips. Nothing helps. Then spent some nice time and trail and error methods found the problem and fixed.
More details about exception:
No item exists at http://mysharepointsite/Pages/Home.aspx?id=4&q=HQ. It may have been deleted or renamed by another user.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: Microsoft.SharePoint.SPException: No item exists at http://mysharepointsite/Pages/Home.aspx?id=4&q=HQ. It may have been deleted or renamed by another user.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
What's the problem?
The problem is in my custom ASPX page, I am using a querystring with the key "id". Do you believe this? which is causing the problem?
Yes, 100% sure. This is what causing the problem. This problem came in my two successive SharePoint projects and finally by changing the querystring key from id to someother key named like "sid" or "aid" or something other than "id" worked.
I am not really 100% sure what's happening when I use "id" key in the querystring, but by changing that everything works fine. So, don't use the querystring "id" in your cusotm SharePoint ASPX pages.
Note: There are chances that you may think the page is checked out or removed by some other user, then that's a mistake.
Hope this helps and save you from killing so much time to know the problem.
Thanks a lot!
ReplyDeleteThis post saves me hours of debugging.
I also use ID in my query string and have the same problem. After I changed it to be something else everything works.
thnks a lot fr this soln.. amazingly it works.. saved lots of time fr me.. i really appriciate u posting it.
ReplyDeleteregards,
nachiket - goa
nachiketkamat@hotmail.com
Thanks a lot!!! I also was having this problem, as soon as I changed it to something else, it works perfectly!!!
ReplyDeleteThank you again!!!
Thanks a lot. I solved it.
ReplyDeleteI ran into the same problem and found that changing 'DefaultValue' form 0 to 1 in the line below cleared up the issue.
ReplyDelete〈ParameterBinding Name="ListItemId" Location="QueryString(ID)" DefaultValue="0"/〉
You are amaizing man, i was playing here and there for hours to figure out what the problem is. changing to AID solved all the issues.
ReplyDeleteI love people like you and Google. It would take for ever if it wasn't for you!
ReplyDeleteStill , i have same problem, i m using feature which redirect form Contact list to MyCustom page on that page i m deleting that record, i cant change the ID from query string is there any thing to solve that issue
ReplyDeleteHi Aamir,
ReplyDeleteI am not understanding completely what are you talking about. You have developed a custom page and you are redirecting to this page but when? and if it is a custom page, then you can use whatever querystring you want right? Give me more details, so that I can help.
Thanks a lot!
ReplyDeleteMartin
Certainly, this magic saved my lot of time!!! Thank you very very much about your posting!!!
ReplyDeleteThanks for the fix. Don't know exactly why this happens. As always, your blog is Awesome!
ReplyDeleteThanks for the fix. Don't know exactly why this happens. As always, your blog is Awesome!
ReplyDeletehi praveen ,
ReplyDeletei am facing same problem but i am not creating any custom aspx page.i am creating a sequential workflow and set permission . approver only can view this page. if others login i get this error . how can i avoid this problem . thanks .
my mailid: muthupandi.a@hotmail.com
If you are not using Querystring ID in the page, then the second option could be, the page is not checkedin/published by author to be available to all users! Please check.
ReplyDeleteI too have the same issue.. I too don't have any custom page.
ReplyDeleteI just have a list that is associated with OOTB approval workflow with content approval.
Whenever a new task is assigned, approver tries to locate it in task list to view it before approval, but as soon as the item is clicked, this error pops up.
Praveen, do you have any solution for the question posted above(oct 23rd,2012)?.. please help...
ReplyDeleteThanks
Hi there,
ReplyDeletePlease check that the item is exists in the task list and which is available for all users. The approver should have access to the task list with contribute permission. For testing the issue, please do this. Give full access to the user for task list and test out the process. If still same issue coming then we might need to go through logs.
-Praveen.
Hi Parveen, Thanks for your reply..
DeleteYes,approver earlier had contribute rights. Now,I had to give her full control to the site to complete the tasks and with full control she was able to view those items, but don't know why error poped up with her having contribute rights.
and this issue came up recently. earlier, she was able to view it even with her contribute rights.
please suggest what shoud be done
First thing you don't need to give full control to site. Full control to list is enough. This way they don't get access to full site. And about contribute permissions, I need more information on how the item/task is getting created? Check once the item created is visible to all people who has read access...
Delete-Praveen.
I agree.. but i dont have unique permission set up for the task list, it inherits its permission from the top site.
ReplyDeleteand I have OOTB approval workflow associated to a list, whenever an item is added to that list workflow gets instantiated and task is added to task list for approver to view it and approve it. so when ever approver tries to view the newly added item through the task list, she gets this error..
OK. That make sense. If this is the case, the item created through code or manually by a user in the list? The only scenario I am thinking here is below.
Delete"An item is getting created in the parent list. But, the list item is in draft mode (May be you enabled publish options with versioning.)". So, when item created it is not yet available to all users, until it is approved. But, workflow triggers when a new item is created and it creates a task list item. And end user get notified and when they click on link to read the task, as the task is associated with the list item which is not yet approved/published to all users you might get this error.
Can you check is this happening your end? If it is happening disable the option on parent list "Require content approval option" from the list settings for testing if possible.
thanks
-Praveen.
And go through the link once for better understanding of what I have said above.
Deletehttp://office.microsoft.com/en-us/sharepoint-server-help/use-a-workflow-to-manage-content-approval-for-a-library-HA010172010.aspx
yes, it is exactly what is going on.. but if I disable content approval field, even before my approver approves the workflow item it is visible for all the users. that is why I had content approval feature on.
ReplyDeleteThanks for the link, I have gone through this already... I have the same thing set up..
ReplyDeleteHi there (I don't know your name.),
ReplyDeleteI believe the issue could be the user only have contribute access. But to approve the item, they should need Approve rights as well. Do one thing, if all the approvers are in a group then change the permissions of the group to have CONTRIBUTE and APPROVE permissions. If user not in any group then change their permissions to CONTRIBUTE and APPROVE permissions. This should fix the issue. Good day. :)
Hello.. the Approver for the workflow is already in the approver's list. She has both contribute access(of the site) and approver permissions (for the workflow) what else access are you referring to?
ReplyDeleteI think I didn't Understand...
Btw my name is Manisha
Hi Manisha,
ReplyDeleteSorry for the delay. This is very interesting issue. For approving any workflow item the permissions required are "Contribute" and "Approve". If they have both access then it should work. Seems like it is a special scenario we have to look deeper. When the error comes please check the logs and see what exact exception message it is recorded. If it is something related to Permission issue then please post that here.
Sorry, I am unable to here in the issue. Praveen.
I do not feel there is really any value writing such big blog posts, when these issues have already been addressed by Microsoft Support teams.
ReplyDeletePraveen, I do not have anything against you, but personally, I feel, I would see this issue resolved at microsoft.support, fix my defect and blog by posting the URL for quick references to all.
What a waste of time here, please utilize your strength in doiung more fruitful stuff.
Again, no grudges....just a plain beneficial advice.
Hood da frootz !! that would have taken days to figure out.
ReplyDeletethank you
Where do we change the ID at? as I don't see a Query String item.
ReplyDeleteI'm using a dataform webpart and trying to pass the ID of the list item to the a custom DispForm.aspx page.
I also Do not see this line of code anywhere in the Dataform Webpart:
〈ParameterBinding Name="ListItemId" Location="QueryString(ID)" DefaultValue="0"/〉
but the error message is the same you are referring to
Thanks a lot for this post, it saved me alot of valuable time !
ReplyDelete