Notifications
Announcements
No record found.
I have two forms FormA and FormB, when open FormB from FormA the cursor always points to the first record. I want to make the cursor of FormB points to the record related with FormA.
I tried tableB_ds.positionToRecord(record) but it is not working. I also tried tableB_ds.findRecord(_record) and none of them worked with me.
Hi CSafwat,
Please check this thread. It answers a question similar to the one you have.
Usually, you can achieve this behavior by implementing a relation between the caller table on FormA and the root table on FormB. Do you have this kind of relations between tables?
Hi Gunjan,
I can't use this solution as it's not the main datasource of the Form.
Hi Sergei,
actually they have relation but the problem is tableA in FormA have relation with tableB in FormB but tableB is not the main datasource of FormB. so, I am trying to make the cursor of tableB points to the correct position. whenI used tableB_ds.findRecord(_record) the cursor gets the right record but when the form opened the cursor returned to the first record.
Hi,
Could you please help us with the complete scenario to test this behavior in standard environment.
If it's the main data source, you'll get a dynamic link automatically, but you can explictiyl use addDynalink to add it to a different data source (and let the standard logic do the rest).
I used this technique in DataReferenceSearcher, therefore you can look at a concrete example there.
Thank you all.
I solved the problem by using tableB_ds.positionToRecord(record) but calling it in linkActive() method of the form datasource.
Under review
Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.
As AI tools become more common, we’re introducing a Responsible AI Use…
We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…
These are the community rock stars!
Stay up to date on forum activity by subscribing.
Martin Dráb 565 Most Valuable Professional
André Arnaud de Cal... 450 Super User 2025 Season 2
Sohaib Cheema 250 User Group Leader