cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
insp33
Regular Visitor

New read-only columns in Sharepoint list blocking PowerApp?

Hello,

 

I have a SharePoint list that I would like to download to PowerApp, edit, then upload. The code below downloads and uploads, and is in a button for testing.

 

If(Connection.Connected,
ClearCollect(_InspectItems, Filter('Inspection Summary', Inspector_LastName=_LastName, Inspector_FirstName=_FirstName)));
If(Connection.Connected, Patch('Inspection Summary', _InspectItems));

 

When running this, I get the error:

 {FilenameWithExtension}: The specified column is read-only and can't be modified.

 

I can not find this column in my SharePoint list. It seems like something internal to SharePoint that was recently added? So I excluded this column. Then more errors due to other hidden columns so exclude them too:

If(Connection.Connected,
ClearCollect(_InspectItems, DropColumns(Filter('Inspection Summary', Inspector_LastName=_LastName, Inspector_FirstName=_FirstName),
"Author","ComplianceAssetId","{FilenameWithExtension}","{FullPath}","{HasAttachments}","{Identifier}","{IsFolder}","{Link}",
"{ModerationComment}","{ModerationStatus}","{Name}","{Path}","{Thumbnail}","{TriggerWindowEndToken}","{TriggerWindowStartToken}","{VersionNumber}")));

 

Now I am stuck on this error:

Author#Claims: The specified column is read-only and can't be modified.

 

DropColumns() does not recognize this column so I am not able to exclude it. Any ideas on how to exclude this column and any additional hidden, read-only columns that may show up?

 

Thank you very much!

1 ACCEPTED SOLUTION

Accepted Solutions

Thanks @insp33 ,

Firstly you are correct that SubmitForm will never work offline as you cannot present a record from a Collection in a form.

However if you Patch (or UpdateIf) using columns, you need the Syntax below to tell Power Apps which record to update.

UpdateIf(
   YourListName,
   ID=YourGalleryName.Selected.ID,
   {
      Field1:Control1Value,
      Field2:Control2Value,
      Field3:Control3Value
   }
)

 

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.

 

 

View solution in original post

11 REPLIES 11
WarrenBelz
Super User III
Super User III

Hi @insp33 ,

Try using AddColumns to add only the ones you are gong to change

If(
   Connection.Connected,
   ClearCollect(
      _InspectItems, 
      AddColumns(
         Filter(
            'Inspection Summary', 
            Inspector_LastName=_LastName, 
            Inspector_FirstName=_FirstName
         ),
         "Column1",
         "Column2",
         "Column3"
      )
   )
)

 

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.

I gave up on that because there are almost 200 columns and the column headers shown in SharePoint list do not match what I needed to use in PowerApp. That's why I went in the other direction to exclude. 

@insp33 ,

How many of the columns are likely to be changed?

All of columns will be changed in PowerApp. About 200.

 

Unfortunately, the SharePoint list headers were renamed over time, so I don't have the original names that I can use in PowerApp. Trying to figure out those names have been very challenging. At least PowerApp is telling me which column is read-only and I can exclude those, except for this last one.

Hi @insp33 ,

I can help with one problem - if you hover over the field name in List Settings, you will see the original name in the bottom panelColumnNames.png

Is there any reason you are simply not presenting a form based directly on the list with the fields you require and then simply using SubmitForm()?

 

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.

That is helpful in other ways. In this case, I am experiencing a lot of typos entering ~200 of these types of column names for PowerApp.  👓

 

CRSN100KVA%5Fx002d%5F7200%5Fx002f%5F1247

 

I have not been able to get the SubmitForm() to work offline.

BTW, I tested keeping a couple of the columns that I want, rather than these read-only columns. The result is that the upload creates a new row in SharePoint list, rather than editing the existing row that was downloaded. This suggests there are other columns that I need to keep for this to work. 🤔

Thanks @insp33 ,

Firstly you are correct that SubmitForm will never work offline as you cannot present a record from a Collection in a form.

However if you Patch (or UpdateIf) using columns, you need the Syntax below to tell Power Apps which record to update.

UpdateIf(
   YourListName,
   ID=YourGalleryName.Selected.ID,
   {
      Field1:Control1Value,
      Field2:Control2Value,
      Field3:Control3Value
   }
)

 

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.

 

 

View solution in original post

I did a test with a few of my columns plus "ID" and this works. So now I better start transcribing all ~200 columns because this is gonna take a while... Thank you very much! 👍

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

R2 (Green) 768 x 460px.png

Microsoft Dynamics 365 & Power Platform User Professionals

DynamicsCon is a FREE, 4 half-day virtual learning experience for 11,000+ Microsoft Business Application users and professionals.

Users online (1,921)