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
Syndicate_Admin
Administrator
Administrator

Can you please help me with how we can add Multiple formulas to an ITEM Property

Can you please help me with how we can add Multiple formulas to an ITEM Property

1st Formula :

If(_filter="" , <> , Filter(<>, Status.Value =_filter)

2nd Formula :

SortByColumns(<>,"Request_no",Descending)

3rd Formula :

If(varPageNumber=1, FirstN(<>,ddPageSize.SelectedText.Value*varPageNumber),
LastN(FirstN(<>,ddPageSize.SelectedText.Value*varPageNumber), ddPageSize.SelectedText.Value*1));

when I add Semicolon (;) then it gives me an error

'Expected operator. We expect an operator such as +, *, or & at this point in the formula.'


please help me out with this I am stuck for the last 2 days

2 REPLIES 2
Syndicate_Admin
Administrator
Administrator

Hi @vishv8715 ,

Try this

With(
   {
      wPages: Value(ddPageSize.Selected.Value) * varPageNumber,
      wSize: Value(ddPageSize.Selected.Value),
      wList:
      SortByColumns(
         Filter(
            <>,
            (
               Len(_filter) = 0 ||  
               Status.Value =_filter
            )
         ),
         "Request_no",
         Descending
      )
   },
   If(
      varPageNumber=1, 
      FirstN(
         wList,
         wPages
      ),
      LastN(
         FirstN(
            wList,
            wPages
         ), 
         wSize
      )
   )
);

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Visit my blog Practical Power Apps

Syndicate_Admin
Administrator
Administrator

HI @vishv8715 ,
Try using something like below - 

If(varPageNumber=1, FirstN(SortByColumns(If(_filter="" , <> , Filter(<>, Status.Value =_filter),"Request_no",Descending),ddPageSize.SelectedText.Value*varPageNumber),
LastN(FirstN(SortByColumns(If(_filter="" , <> , Filter(<>, Status.Value =_filter),"Request_no",Descending),ddPageSize.SelectedText.Value*varPageNumber), ddPageSize.SelectedText.Value*1));

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 Solution Authors
Top Kudoed Authors