1142
Views
5
Comments
Solved
Using toObject to convert entity to object and vice versa
Question

Hi, the toObject function is able to convert and entity to an object. Is there a way to cast back the object to the entity? 



2020-09-15 13-07-23
Kilian Hekhuis
 
MVP
Solution

No, unfortunately there is no way to do that. Once an Object, always an Object. But feel free to vote for my Idea here :).

2018-12-17 04-50-28
Manish Pandey

Hi Joachim,

You have to manually convert object to entity ,there is as such no outsystems provided function to convert the same.


Thanks,

Manish 

2020-09-15 13-07-23
Kilian Hekhuis
 
MVP

Manish, how would you "convert" them "manually"? There is no way to do that!

2018-12-17 04-50-28
Manish Pandey

Hi Kilian,

My intention to say convert manually means again you have to retrieve the object and convert this to your entity by assigning values.

Note: I haven't tried this approach but hope this will work :)


Thanks,

Manish

2020-09-15 13-07-23
Kilian Hekhuis
 
MVP

Manish,

It's clear you have no clue what you're talking about. Please stay out of this.

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