How would I accomplish creating this structure in code using JSONItems?
{
"Current":"mypass",
"LastChanged":0,
"Passwords":[
{
"Password":"mypass1",
"LastUsed":0
},
{
"Password":"mypass2",
"LastUsed":0
}
]
}
I keep getting a JSONException when trying to add the second item.
[code] Dim Passwords As new JSONItem
Passwords.Value(“Current”) = “mypass”
Passwords.Value(“LastChanged”) = 0
Dim pwd As new JSONItem
pwd.Value(“Password”) = “mypass1”
pwd.Value(“LastUsed”) = 0
Passwords.Value(“Passwords”) = pwd <<< Don’t think this is right
pwd = new JSONItem
pwd.Value(“Password”) = “mypass2”
pwd.Value(“LastUsed”) = 0
Passwords.Child(“Passwords”).Append(pwd) <<< JSONException
[/code]