Project Server 2007 Event Handler not registering...

คำถาม Project Server 2007 Event Handler not registering...

  • 2012年3月29日 上午 10:34
     
     

    Hi,

    we have created an event handler which is not getting register, in the server settings, basically it doesn't appear inside the PS Event handler section.

    any idea on the same..!!?



    Thanks, Parth

所有回覆

  • 2012年4月2日 上午 07:29
     
     

    Hi Parth,

    Sometimes it takes time, but even after 10-15 mins it doesn't show, check your Event Viewer's Windows Log- Application. There must be some error coming up, most commonly its the assembly or class name that causes error. Do check that and let us know we'll figure it out.


    Thanks, Kashif

  • 2012年4月2日 上午 09:59
     
     

    We checked the Event Viewer for Error, there is no Error ?

    but strange thing i notice is Event Service is not running even if we make it as Started.

    does this make any diff?? as after starting the service we are registering the Dlls but Still no luck :(


    Thanks, Parth

  • 2012年4月2日 上午 10:37
     
     
    Can you tell what your class is inheriting and methods you've overriden.

    Thanks, Kashif

  • 2012年4月2日 上午 10:41
     
     

     public class CreateSurvey:ReportingEventReceiver
        {
           
           
            public override void OnProjectWorkspaceCreated(PSContextInfo contextInfo, ReportingPostProjectWorkspaceCreatedEventArgs e)
            {
                //base.OnProjectWorkspaceCreated(contextInfo, e);
                string projectname=getProjectURL(e.ProjectGuid);
                
                using (SPSite oSPsite = new SPSite("http://dev/pwa/"))
                {
                    oSPsite.AllowUnsafeUpdates = true;            
                  
                    using (SPWeb oSPWeb = oSPsite.OpenWeb())
                    {
                        oSPWeb.AllowUnsafeUpdates = true;
                       
                        SPListTemplateCollection lstTemp = oSPsite.GetCustomListTemplates(oSPWeb);
                        SPListTemplate template = lstTemp["SurvayTemplate"];
                        oSPWeb.Lists.Add("Survey", "Description", template);
                        oSPWeb.Update();
                        SPList SurvayList = oSPWeb.Lists["Survey"];
                        SurvayList.OnQuickLaunch = true;
                        SurvayList.Update();
                        oSPWeb.AllowUnsafeUpdates = false;
                    }


                    oSPsite.AllowUnsafeUpdates = false;
                }
            }
           
        }


    Thanks, Parth

  • 2012年4月2日 上午 10:48
     
     

    What's your full assembly and class name and what you've added to the event handler and to what event you've added.


    Thanks, Kashif

  • 2012年4月2日 上午 11:34
     
     

    assembly Name: e2e_ListCreateOnWsCreatedEvent

    class name: CreateSurvay

    event : OnProjectWorkspaceCreated


    Thanks, Parth

  • 2012年4月2日 下午 12:23
     
     

    Have you registered the assembly in the PWA event handler as following sample

    Assembly: dll name, Version=1.0.0.0, Culture=neutral, PublicKeyToken=xxxxxxx

    Class: namespace.CreateSurvay


    Thanks, Kashif

  • 2012年4月4日 下午 07:27
     
     

    Were you able to solve your problem?


    Thanks, Kashif

  • 2012年4月10日 上午 06:38
     
     
    same is running fine on other server, but not on the production!! :(

    Thanks, Parth

  • 2012年4月10日 上午 11:17
     
     
    Check your ULS as well, you may find something there and restart your Microsoft Project Server Events Service 2010 service. Not sure this will help but at least you can give it a try.

    Thanks, Kashif

  • 2012年4月10日 上午 11:20
     
     

    We have started the Services several times and Its Project Server 2007 not the 2010. 

    And yes will update after checking the same.


    Thanks, Parth