IT:AD:K2:Development:HowTos:Create and Edit Code Activities
Situation
You are creating a workflow, and the pre-built Activities are not going to cut it, and you have to build some custom code to get the job done.
Solution
Select a Default Server Event from the Toolbox (the one that very clearly hints…hey wow…Code) cause it says “DEfault Server Event (Code)”.
Then right click Server Event/ View Code/Event Item.
Note: It is really really important to not fall into the trap of writting much code directly within an event. You have to think of K2 as just a workflow of Triggers - that activate ICommand based code in external assemblies.
In other words, your code – within K2 – should be one or two lines of code at best…