I have a Parse JSON action for getting data from MS forms (attachment information), which is then parsed as a link. But the attachment image is optional and when image is not attached I get a null error. I've tried the solution to add "null" to the code but it does not work. Hope someone can give a solution to ignore the Parse JSON code when there is no/null data?
{
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": [ "string",
"null"]
},
"link": {
"type": [ "string",
"null"]
},
"id": {
"type": [ "string",
"null"]
},
"type": {},
"size": {
"type": [ "string",
"null"]
},
"referenceId": {
"type": [ "string",
"null"]
},
"driveId": {
"type": [ "string",
"null"]
},
"status": {
"type": [ "string",
"null"]
},
"uploadSessionUrl": {}
},
"required": []
}
}
Solved! Go to Solution.
I've made another solution. Added a condition that checks if the MS form question has been filled. If so it starts the JSON, otherwise the same steps are done without the JSON parse step.
Hi @dashiofhdfsdufs ,
Could you please share more details about your scenario? What are the actions above the Parse JSON operation? Is it possible for you to use a Condition control to first check whether there is no attachment in that field?
Best regards,
Community Support Team _ Jeffer Ni
If this post helps, then please consider Accept it as the solution to help the other members find it.
I've made another solution. Added a condition that checks if the MS form question has been filled. If so it starts the JSON, otherwise the same steps are done without the JSON parse step.
User | Count |
---|---|
89 | |
41 | |
22 | |
20 | |
16 |
User | Count |
---|---|
130 | |
51 | |
48 | |
36 | |
26 |