cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
vish_p
Level 8

Choice field from sharepoint list showing [object Object] error on Data table

I wanted to display datas from two sharepoint lists (both having same datatype columns) in a datatable in my app,all fields are shown without any error,only one field i am getting error and datatype of that field is Choice (as shown below) 

image.pngColumnimage.pngStatus column datatable

now,this particular Status column was having same name and different type earlier in my both of the sharpoint lists,now i didn't change the name ,instead changed the datatype to both Choices ,after that i have tried removing and re adding data sources multiple time ,still this error persists..please help

 

I tried the following formula on OnVisible property on Appscreen : 

AddColumns(POlistitems,"statsvalue",Status.Value) ; ClearCollect(POlistitems,'PO list',PO_2)

but it seems to return no value,please find attached image :image.png

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: Choice field from sharepoint list showing [object Object] error on Data table

HI @vish_p,

 

Can you share a bit more about your issue?

Can you show me the error info about your issue ?

 

I made a test. There is no issue on my side.

22.PNG

 

Set onselect property of the button to :

ClearCollect(collection3,test,test2)

Set items property of data table to:

AddColumns(Filter(collection3,Author.Email = User().Email),"statusvalue",status.Value)

please try to re-create a data table and check if it is solved

 

Regards,

Eason

Community Support Team _ Eason YU
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

4 REPLIES 4
Super User
Super User

Re: Choice field from sharepoint list showing [object Object] error on Data table

Hi @vish_p,

It is not returning items because you are ClearCollecting the list again after using the AddColumns().  The AddColumns() function does not persist so I suggest either changing your Items property in the datatable to 

AddColumns(POlistitems,"statsvalue",Status.Value)

You can then deselect Status and select statsvalue for the fields in your table. 

As an alternative you can create the collection after adding the statsvalue column in your screen OnVisible property as you have done but change the function to 

ClearCollect(POlistitems,AddColumns(datasource,"statsvalue",Status.Value))

then the collection will include the statsvalue field. 

vish_p
Level 8

Re: Choice field from sharepoint list showing [object Object] error on Data table

Actually in my solution the following formula is there in the OnVisible property of APP screen.:

 

ClearCollect(POlistitems,'PO list',PO_2)

 And the following formula is there in the Items property of my Datatable

 

Filter(POlistitems, Author.Email = User().Email)

Now when i reladed app all the fields of datatype Choice from sharepoint list is showing as [object Object]

 

The issue is that i am using Clearcollect function to create a collection of 2 sharepoint lists.

 

Please help me solve it !!!!!!

 

 

Community Support Team
Community Support Team

Re: Choice field from sharepoint list showing [object Object] error on Data table

HI @vish_p,

 

Can you share a bit more about your issue?

Can you show me the error info about your issue ?

 

I made a test. There is no issue on my side.

22.PNG

 

Set onselect property of the button to :

ClearCollect(collection3,test,test2)

Set items property of data table to:

AddColumns(Filter(collection3,Author.Email = User().Email),"statusvalue",status.Value)

please try to re-create a data table and check if it is solved

 

Regards,

Eason

Community Support Team _ Eason YU
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

vish_p
Level 8

Re: Choice field from sharepoint list showing [object Object] error on Data table

Thanks this worked for me 🙂 ,but now i am facing another issue i.e. i used to navigate users to a "Detailscreen" wherein the details of the item selected by the user on the Datatable is used to show.That is the formula on "Onselect"  property of Datatable was :

 

Navigate(detailscreen,Fade)

and the "Items" property of that particular form was : 

Datatable1.Selected

that used to work earlier,now after applying your formula whenever i try with Datatable.Selected i am getting an error : "Invalid Formula Expected a value Compatible with Datasource"

And the datasource for my Detailscreen Form is "POlistitems"(i.e. the cllection of 2 sharepointlists)

Helpful resources

Announcements
thirdimage

Power Apps Super User Class of 2020

Check it out!

thirdimage

New Badges

Check it out!

thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

SecondImage

Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

Top Solution Authors
Top Kudoed Authors
Users online (5,925)