PADFoundationloggingrun-trackingheadermetadatafoundationaudit
Run Header Initializer
Builds a structured run header with machine name, user context, flow name, and run ID. Outputs a formatted header block suitable for logging to file, database, or console. Pairs with Run Finalizer for complete run lifecycle tracking.
0 copies
Section 1: Capture Machine and User Context
Section 2: Build Formatted Run Header
Usage Notes
- Replace
REPLACE_WITH_RUN_IDwith thestrRunIdgenerated by the Variable Bootstrap pattern (e.g.,RUN-20260320-143022) - Replace
REPLACE_WITH_FLOW_NAMEwith a hard-coded literal string identifying your flow (e.g.,$'''Invoice Processor''') strRunHeaderproduces a single pipe-delimited line suitable for logging to file, Dataverse, or console output- Pairs directly with Run Finalizer — the header is written at flow start, the footer at flow end, creating a complete audit bracket
COMPUTERNAMEandUSERNAMEare standard Windows environment variables available on all machines; no admin rights required- Use
strRunHeaderas the first entry written by Log Detail Writer so every log file begins with full execution context
Requirements
- Windows environment with
COMPUTERNAMEandUSERNAMEenvironment variables set (standard on all Windows machines) strRunIdshould already be initialized by the Variable Bootstrap pattern before this runs- No external dependencies — uses only built-in PAD System and DateTime actions
- Flow must run in attended or unattended mode on a Windows machine (not cloud-only)