2009-06-26 3 views
0

VSeWSS 1.3에서 을 사용하여 사용자 정의 목록 정의 범위를 '사이트'로 지정합니다.ListTemplate 정의의 일부로 사용자 지정 ASPX 파일을 설치하십시오.

<Elements Id="8924acef-84ef-4584-ade4-e3eaeb8df345" xmlns="http://schemas.microsoft.com/sharepoint/"> 

    <ListTemplate Name="MyListDefinition" 
       DisplayName="MyList" 
       Description="" 
       BaseType="0" 
       Type="10888" 
       OnQuickLaunch="TRUE" 
       SecurityBits="11" 
       Sequence="410" 
       Image="/_layouts/images/itgen.gif" /> 

    <CustomAction 
    Id="MyList.Print" 
    Location="Microsoft.SharePoint.StandardMenu" 
    GroupId="ActionsMenu" 
    Title="Print MyItem" 
    Description="Print Empty copies of this form." 
    RegistrationType="List" 
    ControlAssembly="MyList, Version=1.0.0.0, Culture=neutral, PublicKeyToken=de6e0316a726abcd, processorArchitecture=MSIL" 
    ControlClass="MyList.PrintActionMenu" /> 

    <Module Name="ActionPages" Url=""> 
    <File Url="PrintForm.aspx" Type="Ghostable" Path="MyListDefinition\PrintForm.aspx" /> 
    </Module> 
</Elements> 

파일을 'PrintForm.aspx'제대로 아래에있는 서버에 설치되어 ... \ 12 \ TEMPLATE의 \ 특징 ...하지만 이 예상되는 URL 에서을 표시하지 않습니다 http://localhost/site/lists/listname/PrintForm.aspx 목록 템플리트를 설치하고이 템플리트를 사용하여 새 목록 인스턴스를 작성한 후

위의 그림과 같은 ListDefinition.xml 파일의 및/또는 태그에 올바른 속성이 누락되었다고 생각됩니다.

+0

게시물의 코드 일부가 누락되었습니다. pls edit. – Colin

+0

Duh, 서식을 지정하기 전에 전체 코드 섹션을 확장하는 것을 잊어 버렸습니다. –

답변

0

또한의 schema.xml을해야하고의 schema.xml에서 이런 일이 있어야한다 :

<Forms> 
    <Form Type="DisplayForm" Url="DispForm.aspx" WebPartZoneID="Main" /> 
    <Form Type="EditForm" Url="EditForm.aspx" WebPartZoneID="Main" /> 
    <Form Type="NewForm" Url="NewForm.aspx" WebPartZoneID="Main" /> 
    ...... your form here 
</Forms> 

P.S. SharePoint Solution Generator를 사용하여 기존 목록 (VSeWSS와 함께 제공됨)을 내보내려고하면 완전한 xml 정의가 제공됩니다. 이것을 참조로 사용할 수 있습니다.

P.P.S. 코멘트에 게시 된 링크는 파일과 같이 기능에 등록해야한다고 주장한다 : 그것은 어디 인 경우

<ElementFile Location="GenericList\schema.xml" /> 
<ElementFile Location="GenericList\DispForm.aspx" /> 
<ElementFile Location="GenericList\EditForm.aspx" /> 
<ElementFile Location="GenericList\NewForm.aspx" /> 
<ElementFile Location="GenericList\AllItems.aspx" /> 
+0

유형 속성의 값은 무엇입니까? –

+0

확실하지 않습니다. 양식을 목록에 추가 한 다음 SSG를 사용하여 필요한 XML을 리버스 엔지니어링하십시오. 또한 SPSource는 동일한 작업을 수행 할 수 있습니다. – Colin

+0

또한 확인해보십시오. http://www.sharepointdevwiki.com/display/public/Creating+a+List+Template+within+a+Feature – Colin

0

, 나는 당신의 웹 사이트의 루트 폴더에 표시 할 PrintForm.aspx을 기대 할 때 모듈 요소의 URL이 비어 있습니다. 시도해보십시오.

<Module Name="ActionPages" Url="lists/listname">  
     <File Url="PrintForm.aspx" Type="GhostableInLibrary" Path="MyListDefinition\PrintForm.aspx" /> 
    </Module> 

또한 Ghostable 대신에 GhostableInLibrary를 파일 유형으로 사용해보십시오.

마지막으로 PrintForm.aspx는 기능의 일부에 표시되지만 전체 경로는 제공하지 않는다고 언급했습니다. ... \ 12 \ TEMPLATE \ Features \ YourFeaturesName \ MyListDefinition \ PrintForm.aspx에 있는지 확인하십시오. Path 속성의 값에 따라 PrintForm.aspx는 Feature 내의 MyListDefinition 디렉터리에 있어야합니다.

관련 문제