Implemented for the next release: https://feedback.objo.dev/feature/356
Dictionary now supports Key(index), so you can do:
For i As Integer = 0 To Entities.Count - 1
Var key As String = Entities.Key(i)
sTxt = sTxt.Replace("#" + key, Entities.Value(key))
Next
The index is zero-based and follows the dictionary’s current enumeration order, the same order used by Keys and For Each. Typed dictionaries preserve the key type, so Dictionary(Of String, String).Key(i) returns a String.