The error occurs because the dictionary dic_message is not initialized before adding values.
Fix:
Before the For Each Row loop, initialize the dictionary using an Assign activity.
dic_message = New Dictionary(Of String, String)
Modify the assignment inside the loop to avoid errors.
If Not dic_message.ContainsKey(row("Code").ToString.Trim) Then
dic_message(row("Code").ToString.Trim) = row("Level").ToString + "," + row("Message").ToString
End If
This ensures that dic_message is properly initialized and avoids key duplication errors.