Skip to content
This repository has been archived by the owner on Dec 23, 2020. It is now read-only.

ModifyAttributes needs to pay attention to possible UserData changes #133

Open
sbaer opened this issue Mar 21, 2013 · 0 comments
Open

ModifyAttributes needs to pay attention to possible UserData changes #133

sbaer opened this issue Mar 21, 2013 · 0 comments

Comments

@sbaer
Copy link
Member

sbaer commented Mar 21, 2013

ModifyAttributes is not recognizing changes to userdata on object attributes.

Rhino.Input.Custom.GetObject go = new Rhino.Input.Custom.GetObject();
go.Get();
Rhino.DocObjects.ObjectAttributes atts = go.Object(0).Object().Attributes;
atts.SetUserString("Jon", "Jon");
Guid id = go.Object(0).ObjectId;
Rhino.RhinoDoc.ActiveDoc.Objects.ModifyAttributes(id, atts, false);
string s = Rhino.RhinoDoc.ActiveDoc.Objects.Find(id).Attributes.GetUserString("Jon");
if(string.IsNullOrEmpty(s))
    Rhino.RhinoApp.Write("NoUserString" + "\n");
else
    Rhino.RhinoApp.Write(s + "\n");
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant