Safe profile photo

Hi, I'm making a mobile app and I'm trying to save the photo of the profile but always appear the error of the photo:


It looks like the Country Id is not passed correctly but without OML is hard to say for sure.

Can you see the error?


Here there is the save onclick


Hello @Gerard Purtí 

Please check if you are  picking up the CountryId correctly in your aggregate. (I checked your oml while it was still available in your post).

It is very likely the CountryId value in the aggregate is NULL.

Thanks a lot Aj, but sorry for my little knowledge about outsystems, I'm knew. To pick up the country Id correctly where I have to go?

This is the aggregate I was referring to

Replying to AJ.'s comment on 27 Sep 2021 19:09Thanks, I checked there, but I don't know how to check if i'm picking up the CountryId correctly in the aggregate 

You could set a breakpoint for e.g. as shown below and turn on debugging and look at the values in the "current" row being processed in the aggregate.

If you are new to debugging an application in OutSystems please refer - 

Yes, that's what I did, but it doesn't work


I could not make the connection between the screenshot you shared and the debugger. I did not see any break points set.

Hello @Gerard Purtí,

Yesterday you had briefly shared your oml. I had saved it before you deleted it for some reason. I have resolved the error you were encountering in the 'Edit Profile' screen and it now saves the Country in the 'FotoPerfil' entity.

Can I post the modified oml here? If you prefer that I do not share your oml in the forum, I can alternatively provide all the screenshots for the changes I made.




I think you break the foreign key constraint and it may be easier to solve if you can upload the oml file. 


It seems you are trying to insert the data with some foreign key but its not fetching the proper ID of that foreign key.

one more thing, in the "1212212.PNG " file, you are assigning the value of any attribute of the aggregate to the input parameter. 

please share your oml file for better understanding of your problem.



Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.