문제

I am trying to add a custom Menu item under "Site Collections" in central admin. Following is my elements.xml file.

<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
    <CustomAction
    Id="CheckAllaboutmoss"
    Location="Micorosoft.SharePoint.Administration.Applications"
    Title="Check Allaboutmoss.com availability"
    Sequence="15"
    RequiredAdmin="Delegated"
    Description="Create a new top-level web site, by host header" 
    GroupId="SiteCollections">
        <UrlAction Url="/_layouts/HelloWorld/Hello.aspx"/>
    </CustomAction>
</Elements>

I deploy the solution and I dont see the new menu item. What could be the reason? I tried adding a menu item to Site Actions menu and it works.

도움이 되었습니까?

해결책

I realize that Location and GroupID attributes mentioned in SDk are not correct: http://msdn.microsoft.com/en-us/library/bb802730.aspx

The values you specified are correct.

I was able to display a link with following XML, which is pretty similar to yours:

<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
  <CustomAction  GroupId="SiteCollections" Id="CheckAllaboutmoss" Sequence="100" Location="Microsoft.SharePoint.Administration.Applications" Title="Check Availability" RequiredAdmin="Delegated" >
    <UrlAction Url="/_admin/createsite.aspx"/>
  </CustomAction>
</Elements>

Please make sure following: 1. You can use Scope = Web or higher (Web makes sense) 2. Make sure you have AutoActivateInCentralAdmin="TRUE" in the FEATURE element of the feature.

다른 팁

Your location is not good. You wrote Location="Micorosoft.SharePoint.Administration.Applications"

instead of

Location="Microsoft.SharePoint.Administration.Applications"

In the associated feature.xml file, make sure to reference the elements file as follows:

<ElementManifest Location="elements.xml" />

Once without thinking, I used the "ElementFile" tag instead and for the life of me I couldn't figure out why the custom action wasn't showing up. I'm not going to own up to how much time I spent trying to resolve the issue.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 sharepoint.stackexchange
scroll top