radio buttons prefilled from database

0
Hello, i'm complete new at modelling. i've build a page with questions. The filling is about radiobuttons with enummerated answers and store them in a entity. so far no problem. But the next time i open the page from this client i want to pre-fill the buttons with the data from te last time. how do i do this?
asked
2 answers
0

Hi Willy, You have to commit (save) the entity with the enumeration attributes. Do this with a save button or a microflow (action button) with a commit in it. When you open the page the next time Mendix will retrieve the saved values :-)

Good luck.

answered
0

It sounds to me like you're creating a new object every time you open the page. Information in Mendix is stored in objects, so if you create a new one each time that's like wiping the slate clean.

Retrieving the object you created the first time round can be done in any number of ways. You could, for instance, display all the objects of the entity you're using in a list view and then select the object you created from that same list view later on. If you want a more versatile (but complicated) solution you can use the Retrieve object action in a microflow and retrieve the object by a unique characteristic instead.

Long story short, it really sounds like you could benefit from digging around in our starter tutorials for some basic beginner's tips. At the least, I would start off with a simple domain model with a single string attribute displayed on the home page with a data grid and a connected data view. Expand from there and you should progress nicely.

answered