Exemple #1
0
        public static void ViewObjectDict()
        {
            var id = Interaction.GetEntity("\nSelect entity");

            if (id == ObjectId.Null)
            {
                return;
            }
            var dv = new DictionaryViewer(  // Currying
                () => CustomObjectDictionary.GetDictionaryNames(id),
                dict => CustomObjectDictionary.GetEntryNames(id, dict),
                (dict, key) => CustomObjectDictionary.GetValue(id, dict, key),
                (dict, key, value) => CustomObjectDictionary.SetValue(id, dict, key, value)
                );

            Application.ShowModalWindow(dv);
        }
 public static string GetData(this ObjectId id, string dict, string key)
 {
     return(CustomObjectDictionary.GetValue(id, dict, key));
 }