Blue Prism Code Stage guides
The Code Stages Blue Prism developers write again and again, done properly: working C#, the namespaces and references each one needs, and the mistakes that cost an afternoon. Every sample compiles with the C# compiler that ships with Blue Prism.
How to write a Code Stage in Blue Prism: inputs, outputs, namespaces and references
A step-by-step guide to Blue Prism Code Stages in C#: where the code goes, how inputs and outputs become variables, the data type mapping, and how to add namespaces and DLL references.
Filter a Blue Prism collection without a loop (DataView and LINQ)
Filter a Blue Prism collection in one Code Stage instead of a Loop, Decision and Calculation: DataView.RowFilter syntax, numeric comparisons, and LINQ with the references it needs.
Remove duplicate rows from a Blue Prism collection
Three ways to de-duplicate a Blue Prism collection in a Code Stage: whole-row duplicates, duplicates by a key column (keeping the first), and multi-column keys — with the case-sensitivity trap explained.
Parse JSON in a Blue Prism Code Stage (no third-party DLL)
Read values from JSON and turn a JSON array into a Blue Prism collection with JavaScriptSerializer, which ships with .NET — no Newtonsoft.Json deployment needed.
Blue Prism Code Stage compile errors and how to fix them
The exact compiler messages Blue Prism Code Stages throw — "is not declared", "type or namespace could not be found", "AsEnumerable", CS0021, CS0266, CS0656, CS0542 — and the fix for each.
Dates in Blue Prism Code Stages: parsing, formats and robot locale
Parse text dates safely in a Blue Prism Code Stage with TryParseExact and an explicit culture, format dates for output, convert Excel serial dates, and add working days.
Regex in a Blue Prism Code Stage: match, extract and validate
Use regular expressions in a Blue Prism Code Stage: first match, all matches into a collection, named groups, validating PAN and IFSC codes, and timeouts that stop a bad pattern hanging a robot.
Code Stage vs Loop stage: making Blue Prism collection work faster
Why looping over a big collection on the Blue Prism canvas is slow, how to move the work into one Code Stage, how to measure the difference yourself, and when the canvas is still the right choice.