Displaying Dict Message

Hi
I have dict, need to display all data in neat format.
Example :Key : Value
“state”:“Country”
line by line in message box.

Please send the syntAX

Hi,

Refer this : Dictionary Key and Values to display in a message box

Hope this helps you

Thanks

I have used this

String.Join(“,”,vari.Select(Function(e) e.Key+“:”+e.Value.ToString).toArray)String.Join(“,”,vari.Select(Function(e) e.Key+“:”+e.Value.ToString).toArray)

I knew this, but in single box I need with neat format

dict>data table>write CSV>displaying output of csv can this help?

@KarthikBallary,

try like this,

String.Join(Environment.NewLine, dict.OrderBy(Function(kvp) kvp.Key).[Select](Function(kvp) kvp.Value))
1 Like

ok insteadof “:” tell the syntax of tab or new line

What is the synatx for tab?

@KarthikBallary, which tab?

means between text , if we press tab it will add more space…

@KarthikBallary,

You can use “vbTab” to get tab, for new line use “Environment.Newline”

Assinn:
StrKey = Valeu1
Strstate = Valeu2
StrStreet = Valeu3

message box exemple

"Cliente Info: “+StrKey+” : " + Strstate + " : " + StrStreet