Help - Custom Workflow Activity
We need to have a custom activity that will unlock an AD account that has been locked. We have the code written that will do this. But we need to put this code into a custom workflow activity so that it can be called in a workflow. This is our first workflow activity where we have to operate on a person object in FIM and we are unsure how we hook into the workflow and get at the attributes about the person the workflow is operating on (eg get the person’s SamAccountName). We have done some WWF work in SharePoint, so we have a little bit of experience in WWF. Any help is greatly appreciated.
April 12th, 2010 10:26pm

I recommend you to have a look at the ILM2 workflow walk through created by the guys at Ensynch and read the superb guide that follows with it... http://ilm2wfactivity.codeplex.com/ Henrik Nilsson Blog: http://www.idmcrisis.com Company: Cortego (http://www.cortego.se)
Free Windows Admin Tool Kit Click here and download it now
April 12th, 2010 10:31pm

Thanks. We used this as a starting point and it helped a little. But I was hoping for more examples, but FIM is just too new. I do have another question though. We have developed a new activity. In order to use this activity in a workflow, I know that it has to be deployed to the GAC and then some configuration stuff has to be done it the portal. But my question is does the DLL have to be added to the GACs of the portal servers as well as the GAC of the server running the FIM service?
April 13th, 2010 7:02pm

Thanks for the plug Henrik, Yes, you will need to deploy your DLL's to any server running an instance of the FIMService. I would recommend a deploy script that copies and registers them across all of your servers. FYI - Joe and Rebecca are working on updating the guide for FIM RTM.Brad Turner, ILM MVP - Ensynch, Inc - www.identitychaos.com
Free Windows Admin Tool Kit Click here and download it now
April 13th, 2010 7:13pm

Check out the reference for the different activities that comes with FIM: http://msdn.microsoft.com/en-us/library/microsoft.resourcemanagement.workflow.activities.aspx It's hard to give you better advise than to check out Ensynch's and my activities (http://idmcrisis.com/?tag=/workflow-activity ) that all are a bit outdated. What you should look at is the Read and Update Resource activities that allows you to read details about a resource and save any changes you've made to it. If you need to lookup resources (for example by sAMAccountName) using XPath you should use the EnumerateResources Activity. //HenrikHenrik Nilsson Blog: http://www.idmcrisis.com Company: Cortego (http://www.cortego.se)
April 13th, 2010 8:19pm

Thanks Brad and Henrik. I think our current stumbling block is getting the FIM Portal to show the custom activity in the workflow designer. We have deployed the DLL to the GAC. We have gone into Activity Information Config and declared the activity there. We have reset IIS and restarted the FIM service. But it still doesn't show up in the WF designer when you add a new activity. Thoughts?
Free Windows Admin Tool Kit Click here and download it now
April 13th, 2010 10:20pm

You must create the UI part as a ASP.Net Server control and register it with the activity. I guess you should read the Ensynch guide a bit more carefully or check out this guide: http://msdn.microsoft.com/en-us/library/ff463694.aspx //HenrikHenrik Nilsson, ILM/FIM MVP Blog: http://www.idmcrisis.com Company: Cortego (http://www.cortego.se)
April 13th, 2010 10:37pm

I downloaded the example http://ilm2wfactivity.codeplex.com/releases/view/20188 and compiled it and deployed it to FIM 2010 using the steps described in the PDF and this activity does not show up. So I'm missing something somewhere.
Free Windows Admin Tool Kit Click here and download it now
April 14th, 2010 12:03am

Couple of things to check/do: Make sure the assembly for your workflow activity is installed in GAC Make sure the information you have provided in your ActivityInformationConfiguration is correct. Make sure the 'Activity Name' specified in your ActivityInformationConfiguration does indeed exist in the assembly specified in the 'Assembly Name' field Make sure you have appropriately marked the activity as either of Action, Authorization or Authentication Restart IIS & FIMService Hope this helped! Thanks & Regards, Jameel Syed Principal Consultant, fimGuru - Your window into simplified identities jameel.syed@fimguru.com - http://www.fimguru.com
April 14th, 2010 12:25am

Thanks Jameel. I did get it to show up now. I think the problem was in the configuration and getting the Activity Name and Type Name correct.
Free Windows Admin Tool Kit Click here and download it now
April 14th, 2010 12:30am

Guys, I need some clarification on something. As per Microsoft’s recommendation, we have our FIM installation configured in the following manner. Server A has the portal and that is it (SharePoint).Server B has the FIM Service and the FIM Synch Service. If I create a new custom activity, what server’s GAC will I install it into? Server A or Server B? Now, let’s say I need to debug this custom activity, keeping in mind the activity has code for the UI part of it and code for the workflow part of it. If I wanted to debug the UI part of the code, it would seem I would have to attach to the w3wp.exe process on Server A. But that would imply that I would have to have the DLL and PDB file deployed on Server A. However if I needed to debug the workflow code, then I would attach to the Microsoft.ResourceManagement.Service.exe process. That would seem then that I have to have the DLL/PDB deployed to Server B.Please help me sort this out.
April 15th, 2010 9:53pm

How about remote debugging?The UI only exist when you configure your activity then it becomes a part of the xaml/xoml workflow. The activity won't be executed unless it a part of the workflow and executed by the runtime.http://msdn.microsoft.com/en-us/library/y7f5zaaa.aspx//HenrikHenrik Nilsson, ILM/FIM MVP Blog: http://www.idmcrisis.com Company: Cortego (http://www.cortego.se)
Free Windows Admin Tool Kit Click here and download it now
April 15th, 2010 10:05pm

I get remote debugging. But my question is in order to do remote debugging and I need to debug the UI code (eg configuring the activity), where is that code actually running? Server A or Server B?
April 15th, 2010 10:33pm

The UI will be executing on Server A and the workflow on Server B.During the configuration of the activity/workflow the activity must be available on server A so that the workflow that is created on server A knows about the activity. When the workflow has been created it's stored as xoml/xaml in your DB and before executed picked up from DB by server B.//HenrikHenrik Nilsson, ILM/FIM MVP Blog: http://www.idmcrisis.com Company: Cortego (http://www.cortego.se)
Free Windows Admin Tool Kit Click here and download it now
April 15th, 2010 10:48pm

Excellent, that is what I thought. So if the production environment was configured as I have said, then the DLL would have to be deployed to both servers. Right?
April 15th, 2010 10:51pm

Yes! :-)Edit: The out of the box activities has it's activities and it's UI split between two separate dll's. If you try the same you might not have to GAC the UI dll on Server B (Service Server) but this probably requires you to register the UI dll in the WSS site config file instead.Henrik Nilsson, ILM/FIM MVP Blog: http://www.idmcrisis.com Company: Cortego (http://www.cortego.se)
Free Windows Admin Tool Kit Click here and download it now
April 15th, 2010 10:55pm

Okay, explain something to me. So if the UI is in one DLL and it is deployed to Server A and the workflow is in another DLL and it is deployed to Server B, then what is the Assembly Name value put into the Activity Configuration for the activity? It is UI DLL or WF DLL?
April 15th, 2010 11:29pm

The WF DLL... The UI DLL must probably be configured in another way so that it's available to the Portal but this isn't anything I recommend, instead keep them both in the same dll.//HenrikHenrik Nilsson, ILM/FIM MVP Blog: http://www.idmcrisis.com Company: Cortego (http://www.cortego.se)
Free Windows Admin Tool Kit Click here and download it now
April 15th, 2010 11:35pm

Okay, makes sense. And I thought SharePoint custom workflows were fun. FIM workflows are a hoot!
April 15th, 2010 11:43pm

Hi everyone, In ILM 2 the name of the dll to develop a workflow with UI was Microsoft.IdentityManagement.WebUI, but in FIM 2010 RTM I dont find it, the Web Portal Folder it was the folder that contains that dll isn't anymore in FIM. Dou you have any idea where i can find the dll for the FIM RTM, Thanks
Free Windows Admin Tool Kit Click here and download it now
June 24th, 2010 2:04am

You can extract it out of MicrosoftILMPortalCommonDlls.wsp. Reference: http://social.technet.microsoft.com/Forums/en-US/ilm2/thread/ce902e07-15fe-40ef-9872-c4f8da83cf80/ Thanks & Regards, Jameel Syed Principal Consultant, fimGuru - Your window into simplified identities jameel.syed@fimguru.com - http://www.fimguru.com
June 24th, 2010 5:55am

There is a custom activity example in the FIM 2010 SDK that is a complete end-to-end example of creating an activity and getting it to show up properly in the portal. http://msdn.microsoft.com/en-us/library/ff859524.aspx
Free Windows Admin Tool Kit Click here and download it now
November 15th, 2010 1:57pm

You should check out this product, you can build that activity very easily, www.cDevWorkflow.com
June 22nd, 2011 6:13pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics