is there any way to create a new page at runtime?
Maybe generate the XAML in cs and add them to the app?
ty
NEW:
Ok i will try to explain it a little better:
i want to create dynamic app-pages from json with multiple controls.
example:
{
"pages": [
{
"title": "Page 1",
"controls": [
{
"button": [
{
"text": "Testbutton",
"value": "clear",
}
]
},
{
"textview": [
{
"value": "enter some text"
}
]
}
]
},
{
"title": "Page 2",
"controls": [
{..}
]
}
]
}
so i want generate them flexible, because the json will be not the same on every load.
You can use XamlReader.Load to create an object tree from xaml.
You can also create the required objects with their constructors and define the tree with the control’s Child properties.