sample activity for copying attribute form refrence object to target object
We are trying to develop a sample activity in FIM through which we can copy attribute from refrence object to destination object.We have used curentrequestactivity to get the current target.in the current object we have refrence attribute. how can we reach to this refrence object and pick up the value.we have tried to use Xpath to reach to the refrence object .can you help us in this i.e how to use xpath in the custom work flow activity.we have also tried to use Microsoft.ResourceManagement.Client. DefaultClient in windows application. how to use this in the Workflow activity..where to put endpoint and also which one is required.
January 28th, 2010 2:59pm

It should be possible to use the web service client but I would recommend you to have a look at the EnumerateResourcesActivity that is the only Activity that comes with FIM that could be used to search for resources using XPath. There is some information on how to use EnumerateResourcesActivity here... http://idmcrisis.com/post/2009/11/16/EnumerateResourcesActivity-the-follow-up.aspx http://c--shark.blogspot.com/2009/04/how-to-use-enumerateresourcesactivity.html http://social.technet.microsoft.com/Forums/en-US/ilm2/thread/4e41c83c-e5be-4f2d-af2a-f6dfb7bf566f Henrik Nilsson Blog: http://www.idmcrisis.com Company: Cortego (http://www.cortego.se)
Free Windows Admin Tool Kit Click here and download it now
January 28th, 2010 3:20pm

Thanks HeNrik...Our requirement is something that we have three text boxes one containg the destination object with the attribute and second containg the target refrence attribute and last with the refrence object with the attribute..eg text1 : [//Target/Address] Target is :current request text2 : [//Target/Office] Office is the refrence attribute that is mapped with Office object. text3 : [//Office/Address] Refrence Object with attribute that needs to be copied into the target attibute.Any idea of how to achive it.
January 28th, 2010 4:52pm

Correct me if I'm wrong... You have a couple of resources (Target) with a reference attribute pointing to an Office resource and you wish to update the Address attribute on the Targets when the reference value for Office is changed on a Target? This could be a solution: 1. Get the Office reference, that would be the FIM Guid (ObjectID) for the office from the Target using the CurrentRequest activity. 2. Create an XPath query where the ObjectID for the Office is incorporated and set it to the EnumerateResources activity. 3. The EnumerateResources activity will iterate once if the Office resource is available in FIM Service and during that iteration (a code activity) you can get the address value for the Office. 4. Use an UpdateResource Activity on your Target resource that sets the address value from the Office resource. This could be the "activity-tree": -Custom Activity --CurrentRequest Activity --EnumerateResources activity ---Code Activity --UpdateResource Activity //HenrikHenrik Nilsson Blog: http://www.idmcrisis.com Company: Cortego (http://www.cortego.se)
Free Windows Admin Tool Kit Click here and download it now
January 28th, 2010 8:15pm

Thanks Henrik ..Only thing when we are using ResourceType currentItem = EnumerateResourcesActivity.GetCurrentIterationItem( ( CodeActivity)sender) as ResourceType; we are able to get.....only problem is when using the CurrentRequestActivity not able to debug the code ....can you please tell us how to add it with EnumerateResourcesActivity..one thing this .enumerateResourcesActivity1.Activities.Add(this.codeActivity1); this .Activities.Add(this.enumerateResourcesActivity1); we are adding CurrentRequestActivity in the main activity.. is it right....
February 1st, 2010 7:09pm

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

Other recent topics Other recent topics