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 :
Finance | Project Operations, Human Resources, ...
Suggested Answer

Run-Time fixed dimension range on query prompt

(0) ShareShare
ReportReport
Posted on by 21
Hi,
 
When the form is opened, the query prompt opens.
Vendtrans has a defaultdimension field, to which the system automatically adds the range option name of /dimension./ at runtime.
I can select it manually at the prompt.
But, I would like to set it fixed when make the query in x++.
How can I do this?
 
I tried this suggestion:
Unfortunately, the lookup option did not work for this.
 
Thank you in advance for your help.
 
Regards,
László
I have the same question (0)
  • Suggested answer
    GirishS Profile Picture
    27,833 Moderator on at
    Hi Horvath,
     
    You can add the range in the executeQuery method or if the form contains query you can add range there.
    Since its a default dimension field how would you identify each dimension values in the code? because the filter in the query prompt shows dimension with values like DefaultDimension.CostCenter, DefaultDimension.Department etc in the lookup.
    I am not sure on this, but you can refer to DefaultDimensionView and add that range to the table which will have values against each dimension values.
     
    Thanks,
    Girish S.
  • Horvath Laszlo DAX Profile Picture
    21 on at
    Hi,
     
    The range must be included in the list, the value of the range must be modifiable by the user.
    In this case, ExecuteQuery does not run yet.
     
    Regards,
    László
  • GirishS Profile Picture
    27,833 Moderator on at
    In that case have you tried adding the range in the init method of the form?
     
    Thanks,
    Girish S.
  • Horvath Laszlo DAX Profile Picture
    21 on at
    Hi,
     
    Yes, that's exactly what I want, to add a range to the query in the init method, which is only added by the processor at runtime.
    The "Dimension." selection in query is not yet available in init method. But I wonder if there is a trick for this.
     
    Regards,
    László

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!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 527 Super User 2026 Season 1

#2
Giorgio Bonacorsi Profile Picture

Giorgio Bonacorsi 473

#3
Adis Profile Picture

Adis 284 Super User 2026 Season 1

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans