cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

how to set automatically a value to an attribute on a meta-association

fuliggians
Super Contributor

Hi, 

 

I'm in this situation: 2 metaclasses with one meta-association in between.

I create a meta-attribute on the meta-association (a datetime format).

 

What I need is to set the current date on the meta-attribute when the meta-association between 2 objects is created.

Is it possible? I see that, on the "characteristic" pannel of the meta-attribute, there is the possibility to set a default value and also to associate a macro. But I was not able to use macro to set the value automatically.

 

In alternative, I know I could create a new button and link to them a macro able to create the meta-association and set specific value, but I was not able to manage it inside the meta property page 😞

 

Could you pls help me?

thanks in advance

 

 

2 Replies

thanks. this is exacly what I need. I have integrated the standard meta-attribute into my MPP.

 

best regards

pvandeginste
Honored Contributor

Hi,

 

out of the box, there are "link creation date" and "link modification date" MetaAttributes. Does the "link creation date" not meet your need?

You can see those attributes for example when you explore the first object: in the explorer window, open the properties of the connected object, and scroll to the bottom of the "General" section in the "administration" tab. You should be able to see when the link was created, last modified, and by which user. You may need to check your MetaModel access setting in the "Tools > Options > Repository" window if you don't see it (I don't remember if the visibility of those attributes are tied to "advanced" or "Expert").

 

Hope this helps.

Philippe