Retrieving keys and values from a .NET hashtable as strings

1 view (last 30 days)
I came across a snippet of code written in MATLAB invoking an .NET assembly, creating an instance of a class and then access methods of the class using that object. One of the methods returns a .NET hashtable. I want to know if there is a way to convert the keys and values of this .NET hashtable to usable data types in MATLAB. I have so far been unable to find any documentation or online help to do this.
ht =
Hashtable with properties:
IsReadOnly: 0
IsFixedSize: 0
IsSynchronized: 0
Keys: [1×1 System.Collections.Hashtable+KeyCollection]
Values: [1×1 System.Collections.Hashtable+ValueCollection]
SyncRoot: [1×1 System.Object]
Count: 1
What would be the right way to extract the information in this .NET hashtable object? Ideally, I would want the values as strings.

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!