Till now, that was one of my toughest assignment, my requirement was to find all pages which customized or changed from SharePoint designer, visual studio and any editor tool, when I started working on the requirements, I thought that I can easily find page customized status (ghosted/unghosted) from SharePoint object model - page CustomizedPageStatus enumeration, but that flag gave me wrong value, I mean, I can’t see my pages as customized which I created from SharePoint Designer.
At one time, I don’t know what to searched in Google, because I tried all combination of search query to get some useful output, but It didn’t bring me anything, all search result gave me idea and links about ghosting, how to customize page and how to reset to site definition from SharePoint designer, etc…..
After some time, I have found one link which says how to deal and work with SharePoint content database, so I started playing around with content database and I have found out that I can write a query which will give me page customization status, SharePoint stores all the information into database, “ALLDOCS” table has all information regarding page size, version, attached list, modified user, time and many more ….
By looking into schema for ALLDOCS table, I created database query and finally I got my result and I was so happy to see the result :)
Below is sample query which will give us all the pages which customized/created from SharePoint Designer, Visual Studio or any other editor tool.
QUERY:
SELECT
W.Title, W.FullURL,
D.DirName + '/' + D.LeafName as pageName,
TimeLastModified as ModifiedTime,
*
FROM
Alldocs D With (NoLock)
JOIN Webs W With (NoLock)
On W.ID=D.WebID
WHERE
D.hasstream = '1'
and D.extension = 'aspx'
and D.iscurrentversion = '1'
and D.setuppath is NULL
Reference Links:
ALLDOCS table schema – columns and its description
http://msdn.microsoft.com/en-us/library/cc704495.aspx
Database table information to find page customized status
http://sky-soft.net/SkySoft/Documentation/WSS/WSSv3Notes.htm
Information about SharePoint content database
http://www.sharepointu.com/ethan/archive/2007/09/16/inspecting-the-sharepoint-content-database.aspx
Query to find list of documents from site collection
http://stackoverflow.com/questions/213801/sharepoint-2007-sql-query-to-find-a-list-of-documents-in-site-collection
After finding my result from database, I thought to tried into SharePoint object model, here is link for finding page customization status from object model.
Showing posts with label visual studio. Show all posts
Showing posts with label visual studio. Show all posts
Friday, May 29, 2009
How to find page/site customization status – Part 1 – with the help of Content Database Schema
Error occurred while starting of workflow (Could not load file or assembly Load Workflow Assembly System.IO.FileNotFoundException)
I was so frustrated to resolved above workflow error, because when I deployed my visual studio workflow solution package and started the workflow (manually or item created) then I was getting error in workflow status as “Failed on Start (retrying)”, also I didn’t see much useful information into workflow history, after looking into SharePoint log file, I have found below error.
Error:
Could not load file or assembly Load Workflow Assembly: System.IO.FileNotFoundException: Could not load file or assembly ‘ABC.dll, Version=1.0.0.0, Culture=neutral, PublicKeyToken=xxxxxxxxxxx' or one of its dependencies.
I know that there was some problem into feature.xml or workflow.xml file into solution package, but after looking into details, I have found out that I made very silly mistake into workflow.xml file, there was one tag called “CodeBesideAssembly”, we need to write only assembly name like ABC into that tag, but I wrote ABC.dll into CodeBesideAssembly tag into workflow.xml file which caused the error while starting of workflow.
After removing extra DLL word from the file, my workflow was worked fine. So be careful while making workflow.xml file.
Keep Sharing…
Error:
Could not load file or assembly Load Workflow Assembly: System.IO.FileNotFoundException: Could not load file or assembly ‘ABC.dll, Version=1.0.0.0, Culture=neutral, PublicKeyToken=xxxxxxxxxxx' or one of its dependencies.
I know that there was some problem into feature.xml or workflow.xml file into solution package, but after looking into details, I have found out that I made very silly mistake into workflow.xml file, there was one tag called “CodeBesideAssembly”, we need to write only assembly name like ABC into that tag, but I wrote ABC.dll into CodeBesideAssembly tag into workflow.xml file which caused the error while starting of workflow.
After removing extra DLL word from the file, my workflow was worked fine. So be careful while making workflow.xml file.
Keep Sharing…
Labels:
CodeBesideAssembly,
Could not load file or assembly Load Workflow Assembly System.IO.FileNotFoundException,
Failed on Start (retrying),
feature.xml,
Personal Experience,
Sharepoint Problems,
solution package,
visual studio,
Visual Studio Workflow - SharePoint,
Workflow,
workflow.xml
Subscribe to:
Posts (Atom)