Active Query Builder support area

LinkCreated event fired only when a link is created manually ?

Avatar
  • updated
  • Completed
Hi,

in metadata there are foreignkey between some tables, when I add those tables to the query, the link is created correctly.

I need, in some case, set up a left join, but while It works correctly if I create the link manually, if the link is created automatically (CreateLinkFromForeignKeys=true) the event is not fired.

Thanks
Avatar
Andrey Zavyalov, PM
Since version 2.7.5.645 the new BehaviorOptions.NotifyOnLinksCreatedAutomatically property is added to let track addition of automatically created links (by foreign keys or by identical field names) using the LinkCreated event.
Avatar
Vincenzo
Thank you very much.
Avatar
Andrey Zavyalov, PM
We realized that it's not possible to track such event in the current version. We will implement the new property that will instruct the component to fire the LinkCreated event for automatically created links. 
Avatar
Andrey Zavyalov, PM
The LinkCreated event is fired only when the link is added by the user. To find links that are added automatically, you should handle the DatasourceAdded event. The addedObject parameter of this event refers to the newly added DataSource object. We will provide the sample code tomorrow.
Avatar
Andrey Zavyalov, PM
The LinkCreated event is fired only when the link is added by the user. To find links that are added automatically, you should handle the DatasourceAdded event. The addedObject parameter refers to the newly added DataSource object. We will provide the sample code tomorrow.