Hi team, i am working on a power apps and need your help in a specific scenario.
Data source : SP List
Overview of app : App is used by HR professionals to feed the input and as per requirement. Power automate is used in backend to send emails. In SP List, have used People or Group type column to capture the email addresses.
Requirement : When user edit the request and update the content than ‘On Submit’ it throws an error ‘Object must implement IConvertible’
This is first time I have seen this error. And this error appear in ‘edit’ mode not in ‘Play’ mode.
Appreciate your help.
Happy to help and glad it is working and you learned some new things!
HI @RandyHayes - First of all thank you so much for helping out many of us in the community. Your response is so fast and helpful. Thank you so much for who you are and what you do.
Later i learned how to properly use 'Monitor' to find out error message.
With challenges we have good learnings!! Thank you.
Get rid of the variables and put your formulas directly in the Update properties for the fields you are trying to update.
However, you might be going down the wrong road. Your issue is with the SubmitForm action and there is something in one of the columns that is being submitted that is causing the problem. However, it might not be the fields that you think!
I would utilize the Monitor Tool to first see what is being submitted. This will give you the best clue as to which column is at fault.
Otherwise, please provide the Update properties for the columns that you currently are using variables in.
Thank you @JR-BejeweledOne for pointing the possible issue.
I have checked the column types used in SP list. Using squared columns in below screenshot as custom data card to accept values stored in variables.
Column - RepeatedSection – Concatenate(NewItemsString1,NewItemsString)
Column RepeatedSectionOnly - NewItemsString
In PowerApps, I removed the column which contain variables and still error is there.
Sometimes error disappear but, while editing a request ‘On Select’ of submit button it throws same error.
Should I change the way to assign variables to data card? Can you suggest any possible alternative please.
Tagging - @RandyHayes @AJ_Z - appreciate your response
Have you customized any of the data cards to contain variable values or anything like that? If so, that could be your problem, you might have a mismatch between what you are putting in the datacardvalue and the column type.
Thank you @JR-BejeweledOne for suggesting good way to check the error part.
I followed the same : And Error appears on 'SubmitForm()'
I checked all the fields in the form and couldn't see any potential issue. Is this something data type issue or something else??
You want to start by isolating where the error is coming from. So for testing purposes, I would put 4 buttons on the screen.
For the OnSelect of each button, break down your submit formula. On the first 3 buttons add one of your UpdateContext formulas and on the last button put your submit. What this will accomplish is to allow you to test each specific command separately in prod. This will allow you to isolate which portion of the OnSubmit is causing the issue.
We can go from there.
Sure @JR-BejeweledOne , thanks for response.
Here is the formula on 'On Select' property of Submit button -->
UpdateContext(
{
NewItemsString: Concat(
galRepeattingTableNewScreen_3.AllItems,
Concatenate( lblItemSerialNumber.Text,
";",
//drpActionItemNewScreen.Selected.'Action Item'
drpActionItemNewScreen_3.Selected.'Action Item',
";",
txtOtherActionItemNewScreen_3.Text,
";",
txtDescriptionNewScreen_3.Text,
";",
drpStatusNewScreen_3.Selected.Result,
";",
txtNotesActionTakenNewScreen_3.Text,
";",
txtClosureOwnerNameNewScreen_3.Text,
";",
dteClosureDateNewScreen_3.SelectedDate,
";",
drpSentimentEditScreen.Selected.Result,
";|;" ))});
UpdateContext(
{ NewItemsString1 :
Concatenate(
"0",
";",
//DataCardValue75_1.Selected.Value,
DataCardValue48_3.Selected.'Action Item',
";",
DataCardValue76_4.Text,
";",
DataCardValue77_4.Text,
";",
StatusValue_4.Selected.Result,
";",
DataCardValue83_4.Text,
";",
DataCardValue51_3.SelectedDate,
"|" )});
UpdateContext(
{
StatusCombined: Concat(
galRepeattingTableNewScreen.AllItems,
Concatenate(
drpStatusNewScreen_3.Selected.Result,
";" ))});
//If(DataCardValue85_1.SelectedDate > Today(), Set(varMessage:"Error",Set(varMessage:"Valid Date"));
UpdateContext({EmailActionPerformed :If(DataCardValue9.Selected.Email <> Blank(),EmailActionPerformed + 1,EmailActionPerformed) });
SubmitForm(frmNewFeedback_3);
Navigate('Feedback Submitted Success Screen')
Above is the formula used.
Can you share your submit formula?
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.