简体   繁体   English

WSS 3.0项目已添加

[英]WSS 3.0 ItemAdded

I am working with WSS 3.0 and trying to set some permissions with the ItemAdded-Event. 我正在使用WSS 3.0,并尝试使用ItemAdded-Event设置一些权限。 The problem is, that the event dont fire if I add an item. 问题是,如果我添加项目,该事件不会触发。 I've searched the whole web and found nothing. 我搜索了整个网络,却一无所获。 It is only on ItemAdding / ItemAdded, yet I have already implemented a ItemUpdating and ItemDeleting Event which are working perfect! 它仅在ItemAdding / ItemAdded上,但是我已经实现了一个ItemUpdating和ItemDeleting事件,它们运行完美! Are there known issues? 有已知问题吗?

This is my Event (It not even get my debugmessages.. :( ): 这是我的事件(甚至没有得到我的debugmessages .. :():

      public override void ItemAdded(SPItemEventProperties properties)
      {
        Debug.WriteLine("ItemAdded started.");
        PMDB_ContentType_Class pmClass = new PMDB_ContentType_Class();

        pmClass.SetPermissions(properties);


        Debug.WriteLine("ItemAdded ended.");
      }

This is the feature.xml 这是feature.xml

<?xml version="1.0" encoding="utf-8"?>
<Feature Id="34e2c6bd-0e9f-4a65-b280-3cd4c5ff5cb4" Title="PMDB_ContentType"           
Scope="Site" Version="1.0.0.0" Hidden="FALSE" DefaultResourceFile="core" 
xmlns="http://schemas.microsoft.com/sharepoint/">
<ElementManifests>
<ElementManifest Location="PMDB_ContentType\PMDB_ContentType.xml" />
</ElementManifests>
</Feature>

1 >> I hope that you have attached you event with your list properly in FeatureActivated Event receiver of Feature. 1 >>我希望您已将事件正确附加到列表中Feature的FeatureActivated Event接收器中。 I cannot check that because you haven't post that code. 我无法检查,因为您尚未发布该代码。 please check if there are any errors in that code. 请检查该代码中是否有任何错误。

2 >> Use Sharepoint Manager (http://spm.codeplex.com/releases/view/51438) to see if your event is properly attached to your list or not. 2 >>使用Sharepoint Manager(http://spm.codeplex.com/releases/view/51438)查看您的事件是否正确附加到列表中。 if not then try to deactivate feature from web UI and reactivate it again. 如果不是,则尝试从Web UI停用功能,然后再次将其重新激活。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM