Couldn't disable editing to user tag



  • THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

    On 06/08/2009 at 18:00, xxxxxxxx wrote:

    User Information:
    Cinema 4D Version:   11.027 
    Platform:      
    Language(s) :     C++  ;

    ---------
    I have the following piece of code that currently wouldn't disable change to the user tag I added to objects:

    DynamicDescription* dd = m_cameraPtr->GetDynamicDescription();

    BaseContainer m_tag;
    LONG datatype = DTYPE_REAL;
    dd->FillDefaultContainer(m_tag, datatype, "mytag");
    // ??? this doesn't really disable change to the tag
    m_tag.SetParameter(DESC_EDITABLE, FALSE);
    m_tag_ID = dd->Alloc(canvasTag);
    m_cameraPtr->SetParameter(m_tag_ID, m_tag, 0);

    What's wrong with it?

    Another question about the user tag BTW: since I use Alloc() function to get the descID, I assume that I might not get the same ID every time. So the only constant here is the name of the user tag. But from the DynamicDescription class help doc, I couldn't find a way to find a user tag by name. Is it simply not possible or there's a way to do it?

    Thanks


Log in to reply