Hello
I have 2 forms, namely AllocationMain and AllocationFinal. For AllocationMain, I have used HcmWorker table from the AOT as the form Data source whereas for AllocationFinal, I have used AK_AllocationFinal table that I have created as the data source. Both the tables have PersonnelNumber as the common Field. In AllocationMain form, I have added ShowAllocation menu item button which has menu item property set as AllocationFinal display menu item. My requiremnet is that when I click ShowAllocation button, I should only see those records from the AllocationFinal form whose PersonnelNumber is same as that of the selected record in the AllocationMain form.
Right now, when I click the ShowAllocation button, it show all the records irrespective of the PersonnelNumber of the selected record in the AllocationMain form.
I have tried adding relation in the AK_AllocationFinal table on PersonnelNumber such that AK_AllocationFinal.PersonnelNumber == HcmWorker.PersonnelNumber.
But this is also not working. I suspect this is because I have used Hcmworker table from the AOT, this is a system table and not present in my solution.
Please help.
The relation looks correct. You surely can make relations to standard tables.
You may want to verify that HcmWorker record is passed to AllocationFinal form through Args. If not, maybe the menu item button has a wrong value in DataSource property, or there is some code interfering with the standard behavior.
If you get the record, it means that the dynalink wasn't created for some reason, or it was removed by some code.
Of course, make sure that your solution is fully (and successfully) compiled, therefore the relation is actually used at runtime.
This should allow you to isolate the problem, at least.
André Arnaud de Cal...
291,969
Super User 2025 Season 1
Martin Dráb
230,842
Most Valuable Professional
nmaenpaa
101,156