Monday, 12 May 2014

CRM 2013 Custom Action as Configuration Entity Replacement

In My Previous Post, I talked about Action in overview. It has great potential and power to extend your xRM Platform. Now, I want to share my experience to use Action to replace a Configuration Entity.

Many thing you can do with Action, this website gives a good example :

http://blog.sonomapartners.com/2013/11/crm-2013-custom-actions-the-end-of-configuration-entities.html

It gives me a good idea and brainstorming.

And here is my example :

1. Create a New Process with Type = Action, make it as Global if you have not decided what specific entity you will use.

image

2. Add Input Arguments, in my case : I have 1 input and 1 Output

image

3. Go to step and make a condition as you did before to create Workflow

image

4. Then after checking condition, create an action message, in this case I put Assign Value.

image

5. Here is assign your value

image

6. Repeat the same steps for SAP as well

image[22]

7. Here is your complete Action

image

8. Using .NET or Javascript you can call this action, remember Custom Action only be triggered by a Code.

This is a good reference :

http://a33ik.blogspot.co.il/2013/10/custom-actions-walkthrough-for-net-and.html

This is like a ‘Code Contract’ that only developers (CRM and Other Party Developer that will use it) to accept desire inputs to result an output, and it is single manageable, that is inside that Action itself.

You can manage your logic here, another application who wants to connect and call this action will only need to give input what do you want and give the output, otherwise, they will be failed to call this action, because you also can do validation inside your Custom Action, I will give you another example later.

But, if you have requirement that User can change it easily and very often, then my recommendation is you are suggested to still use Configuration Entity, since it is easy to be managed and can be managed using Import Wizard (Excel functionality) and no need to do activation then do deactivation again.

My example is for configuration that is not in high frequency changing rate.

No comments:

Post a Comment

Aileen Gusni

Aileen Gusni