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
ckurir
Frequent Visitor

Power BI and Powerapps Writeback whith a Sharepoint List - Seems not to work with a shsarepoint list

I am testing the Write back functionality via Powerapp in Power BI. There are many noce videos to explain how to set it up. But I have not been able to find anything about using a "Sharepoint List" as data source.

I understand direct query is the best, but for this reason I need to develop prototypes with simple excel files or Sharepoint lists.

 

The writ eback here is to eg give comments on each order line in Power BI.

 

Issue:

When I create the powerapp via Power BI it is all good for the first screen, which list all the Comments created. But when I in the Powerapp click on a comment in the first list, in order to see the details, it is not working anymore.

 

The problem comes when I on the detail screen connect the data to the record selected from the first screen, by setting the Item preference = Gallery1.Selected

 

The error message is that the formular is not valid, "a value was expecrted that is compatible with Datasource".

 

I guess there is a problem with IDs or naming of dataelements that makes the connection between PwerBI and SharePoint list in power app not possible.

 

How I set up the connections:

In Power BI I loaded data via the sharepoint list possibility, so via Power Query.

In Powerapp I also make the connection to the same sharepoint list. But it could look like the dataelments are named diffrently from what I see in Power Query for the IDs.

Many "system" fields are coming along with a sharepoint list, like IDs.

 

Any ideas why this should not work and maybe how to fix it?

 

Powerapp screeenshot:

ckurir_0-1621577576784.png

 

 

Power Query Screenshot

ckurir_1-1621577662758.png

 

1 REPLY 1
monta
Frequent Visitor

Hi

I have successfully written data from Power BI back to SharePoint List, so it is possible, but difficult due to following issue...

when you click Edit on your PowerApps visual, and open PowerApps, the data is visible.  However, I'm finding that when I make changes to the app, the data is no longer visible. If I save, close and reopen the data comes back.

I'm not using a Form to write the data to the SharePoint List, just a button with a Patch statement to save data.  This is because I don't need user input, although if I did I would probably just add a text input box to the app.

Patch('Client Scenarios',Defaults('Client Scenarios'),{Client:Client.Text},{Description:"fromPBI"}
,{Yr1Fees:Value(First(Filter(Gallery1.AllItems,YearDate=2022)).Label1.Text)}

I am also  finding I have to be careful that Power BI data types are same as SharePoint list column, otherwise need to convert by e.g. using Value() as shown in the Patch above.

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