Wednesday 19 June 2013

Common SharePoint 2010 Errors And Solutions



Common SharePoint 2010 Errors And Solutions

Error :
Restore-SPSite : Your backup is from a different version of Microsoft SharePoin
t Foundation and cannot be restored to a server running the current version. Th
e backup file should be restored to a server with version '1162887508.196608.17
694860.0' or later.
At line:1 char:15
+ Restore-SPSite <<<<  -Identity http://yousite  -Path D:\.....\....bak   -Force
    + CategoryInfo          : InvalidData: (Microsoft.Share...dletRestoreSite:
   SPCmdletRestoreSite) [Restore-SPSite], SPException
    + FullyQualifiedErrorId : Microsoft.SharePoint.PowerShell.SPCmdletRestoreS
   ite

Solution:
 make sure that your backup file is not  SQL Backup  it must be SharePoint Backup

_________________________________________________________________________________

Error:
Invalid file name.


The file name you specified could not be used.  It may be the name of an existing file or directory, or you may not have permission to access the file.<nativehr>0x81020030</nativehr><nativestack></nativestack>
((

Creating Custom List template and Custom List in Sharepoint 2010 )))




Solution:

make sure the item name (File Name) for List Definition has the same name for Name property in List Template node :
 <ListTemplate  Name="RegistrationTemplate" ... />

_________________________________________________________________________________


Error:
GetUserListSchema(): Failed to get the list schema XML for feature '...', template '...': hr=0x81072101.



Solution:

feature id in list instance is wrong it should be the feature id where list is defined.
so for example if you create ListInstance (Categories) from Custom List (out of the box)
you will get this XML.
<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
  <ListInstance Title="Categories"
                OnQuickLaunch="TRUE"
                TemplateType="100"
                FeatureId="00bfea71-de22-43b2-a848-c05709900100"
                Url="Lists/Categories"
                RootWebOnly="TRUE"
                Description="">
 </ListInstance>

if for any reason you changed the  FeatureId="00bfea71-de22-43b2-a848-c05709900100" to 
 FeatureId="xxxx" you will get this error
GetUserListSchema(): Failed to get the list schema XML for feature '', template '100': hr=0x81072101.




No comments:

Post a Comment