I need to create an dictionary by splitting a string like this:
[SenderName]
Some name
[SenderEmail]
Some email address
[ElementTemplate]
Some text for
an element
[BodyHtml]
This will contain
the html body text
in
multi
lines
[BodyText]
This will be multiline for text
body
The key could be surrounded by anything if that easier, e.g. [!#key#!] i'm interested in getting everything within [] into the dictionary as keys and whatever between the “keys” as values:
key :: value
SenderName :: Some name
SenderEmail :: Some email address
ElementTemplate :: Some text for
an element
Thanks