Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more
Hello
excuse the question. I would like to create a new measure. After giving the name after the = sign I write in DAX. I can't figure out how to wrap by creating automatic line numbering to write on multiple lines.
Thank you
Hello
I found the solution. I probably didn't explain myself.
With shift + Enter you wrap and the lines are numbered
Hi @Gianluigi ,
Since we cannot get wht you really need, this link might help you
Using DAX Variables In Power BI - A Detailed Example | Enterprise DNA
Hello
my problem is not the syntax of dax but that I can not automatically number the lines of code.
Example
DAX =
1 ....
2 .....
3 .....
thank you
I create a new measure as in figure 1. The line number 1 is numbered with the name of the measure after the = sign
How do I wrap so that the second line is automatically numbered with the number 2? as in the second image.
Pressing enter does not wrap.
I hope I made you understand
Hello
For example, this code
1 var1 =
2 VAR _WorkStart =
3 TIME( 8; 00, 0 )
I copied and pasted it. If I want to write it I type var1 = then I would like to wrap so that you number the second line ect. Ect. After writing var1 =
Hi @Gianluigi ,
I think 1 should be the name for first var, you need to add a space between it and VAR function.
Your code should look like as below.
Dax =
VAR 1 = ...
VAR _WorkStart = TIME(8,0,0)
RETURN
...
If this reply still couldn't help you solve your issue, please share a sample file with me.
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, could you please give more information and paste your dax code. If we could get examples of how you would like the formula to work we can help you all the better. Thanks!
Hello
my problem is not the syntax of dax but that I can not automatically number the lines of code.
Example
1 var1 =
2 VAR _WorkStart =
3 TIME( 8; 00, 0 )
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.