web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Formdata sources and getPosition and setPosition does not work

(0) ShareShare
ReportReport
Posted on by 1,413

Hello,

If you get grey hairs when you battle obstacles, I am soon facing a snow white hair cut.

I'm battling an issue, that I can not seem to solve in Dynamics AX 2012.

I have a form using a view.
The view contains several datasources and it is using outer joins.

The form presents an overview of information, but also allows the user to update approval flags on the records shown in the form.
Thus when using these function, updates are made to the tables, that the view is using to show the overview, and thus
I need to refresh the form datasource, when the functionality is used.

This is the root of my problems.

The overview (and overview of hours consumption transactions for a given periode) can contain several 100's or maybe even 1000's of records, depending on the users filtering.
Therefor it is quite important for the user, that the cursor retains it's position or at least re-positions it self at the record, where it resided, when an update causing a research/refresh
was made.

However, as before mentioned the view uses outer joins, which is why

form_ds.research(true)

method will *not* work.

https://cloudblogs.microsoft.com/dynamics365/no-audience/2010/08/05/research-method-on-x-forms/

Also if I open my view in a table-browser, ALL rows have the same recid (1010).


Therefor I am attempting to use the construct:

int position;

position = Form_ds.getposition();
Form_ds.research();
Form_ds.setPosition();

It works *sometimes*.

If the cursor is situated at say position 12, the repositioning of the cursor works.

However placing the cursor on say the 73rd record in the overview, the getPosition / setPosition mechanism does not work,
and the cursor goes to the top of the overview, frustrating me and the users.

Have anyone experienced the same problem, and maybe found a solution ?

Regards
Jacob

*This post is locked for comments

I have the same question (0)

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.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
CP04-islander Profile Picture

CP04-islander 39

#2
Michel ROY Profile Picture

Michel ROY 14

#3
imran ul haq Profile Picture

imran ul haq 8

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans