Dev-BA Collaboration:Part-2

In the series, the next question we generally get is, How about Validations. How can I have one set of validations for Devs in VS only and another set for BAs in a non-VS environment.

To demonstrate that, again I have developed it on top of the sample application we saw in the previous post.

In here, to know that I am in the VS environment, I am assuming that the designer used would be from CustomActivities.VisualStudio.Design.dll. Next, I override OnModelItemChanged and set the property for the activity – ‘inVS’ to true.

In the activity itself, I customize the validation errors if the property ‘inVS’ is set. You can of course add additional validation errors as appropriate for Dev specific scenario or vice versa.

The BasicDesignerWithStyling, which is assumed to be used in the BA non-VS scenario sets to property inVS to false so that the BA specific validations are seen.

In the sample attached, you will notice that the ‘SMTPServer’ property for the ‘SendMail’ activity is not a required property for the BA. However it results into a validation error for the dev in VS scenario.

The next post in the series, we will see the concept of a dummy activity added by a BA in a Workflow and its implementation done by the Dev in VS.