Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
garythomannCoGC
Impactful Individual
Impactful Individual

Report Builder layout - Hidden property expression side effects

Report Builder layout situation.  Have a textbox object 'Page n of m'   positioned on the rhs (right hand side) of the Page Header.

When the report is run the 'Page n of m' object gets printed on the lhs.

Debugging and it looks like only the Image object stays in place from page 1 on.  Textbox, line and rectangle gets shifted on subsequent pages to the lhs after page one.

 

Create blank report, A4 portrait.  Add the simple objects to the rhs of the page header.  Add a simple query to force multiple pages.

All objects in the Page Header are playing nicely and printing where they are positioned.  So that is the sanity check and back to the real report for debugging and why ...

 

Back to simple debug report after finding that the issue is to do with the Hidden property when an expression is used. 

Regardless of vertical positioning of a say Textbox with Hidden property set to expression of   =IIf(Globals!PageNumber <> 1, True, False)  for example.  Any other objects on the page header get shunted the horizontal width size of the hidden object.

CanShrink, CanGrow have no effect.

 

gif video showing the anomaly 

 

So the Hidden property acts differently when set to True as to when set via expresssion.  Hidden value of True setting has no effect on horizontal space whereas when set as an expression and the result of the expression is True the horizontal space the hidden object takes up gets released so to speak and any other objects on the same layout object (header, footer or body) gets moved to the left by the hidden object horizontal width size amount.

 

Looks like a bug with Hidden property when expression outcome is True.

 

Workaround is to place a hidden object on the horizontal plane to the lhs of the object(s) you do not want to move.  With Hidden property set to True.  

 

1 ACCEPTED SOLUTION
garythomannCoGC
Impactful Individual
Impactful Individual

Add tag Tips and Tricks ... and accepted my own solution :}

View solution in original post

2 REPLIES 2
garythomannCoGC
Impactful Individual
Impactful Individual

Add tag Tips and Tricks ... and accepted my own solution :}

v-yangliu-msft
Community Support
Community Support

Hi  @garythomannCoGC ,

 

Thank you for sharing ! This is very helpful to me !

 

Best Regards,

Liu Yang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Kudoed Authors