Unknown error while intializing dictionary's

Explanation: I initialized a nested dictionary and this problem occurred:

Yes, it's not running in the companion also

The allowed types for keys and values are number, text, other dictionaries, booleans, and lists. You are using buttons as values
See more here
http://ai2.appinventor.mit.edu/reference/blocks/dictionaries.html#create-empty-dictionary

Thanks, got it. But is there a specific reason for which we can't use button's as values for keys ?

This is coming in the next release:

Buttons can be considered alive, born when the app opens, living only while the app is open, and dying when the app closes. They are collections of attributes located at some unspecified and varying location in RAM.

A dictionary is normally used for simpler static data structures, though the concept can be stretched to deal with live data (next version AI2, the Myst PC game series' books, Harry Potter magical printed media.)

Just don't expect to convert such a structure to JSON.

Thanks, got it

However, good to hear that this feature is coming in next release.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.