Support #3794
closedHow is IPluginHost.GetVariables supposed to work?
0%
Description
I really am missing something here. I tried to assign it to an iDictionary of my own, but I got an error about a missing cast. I tried to use it directly, but it's missing a bunch of methods like TryGetValue. If I try and retrieve a value from it directly, I never get anything back. If I try to retrieve a value from a key that doesn't exist, it doesn't seem to throw an Exception like MSDN says IDictionaries are supposed to.
What am I missing? I'm pretty new to C# (just started using it in November) so I'm obviously missing something simple here, but I'll be darned if I can figure out what.
Updated by Per Amundsen over 6 years ago
- Status changed from New to Resolved
Sorry, the API was returning a internal dictionary with a struct instead of a string value, I actually just fixed it in #3792.
You can test it using https://adiirc.com/build/AdiIRC64.exe, it also has the strip colors API.
Updated by Per Amundsen over 6 years ago
Also this API is read only, you can use something like host.ActiveIWindow.ExecuteCommand("/set %variable " + text); to add a variable, or host.ActiveIWindow.ExecuteCommand("/unset %variable); to unset, I will think about adding better API's for this.