@elseCartan wrote:
Hello everybody,
i have to find a way to update myion-selectfilling it with options coming from a property when data is arrived from a web service.I'm doing this but it doesn't work:
<ion-item> <ion-label>Data</ion-label> <div *ngIf="mydata != undefined"> <ion-select [(ngModel)]="myproperty"> <ion-option *ngfor="let item of mydata" value={{item.value}}>{{item.name}}</ion-option> </ion-select> </div> </ion-item>mydata is the property with all the values setted after a post to a web service.
In this way i can see only the label. The strange thing is that if i put that code inside a ion-col of a grid, it works. So the gridview continues to update the values inside in automatic?
How can i fix my code without using a gridview?
(I tried also putting a flag in the component to true after mydata is setted and checking the flag on ngIf but with the same result)
Thank you all!
Posts: 1
Participants: 1