Hi Team,
I have been trying to fire the onAfterRenderSurvey event but it is not working also the I have tried all events of onAfterRender* like Page , question they were also not working but onComplete is working fine. Can you please check what am I missing. Following is my code snippet. Thanks.
ngOnInit() {
this.surveyService.getQuestionaire().subscribe((response:HttpResponse<any>)=>{
if(response.status === 200){
this.surveyJSON= response.body.questionnaire;
this.showServey(this.surveyJSON);
}
});
}
showServey(surveyJSON) {
Survey.StylesManager.applyTheme("bootstrap");
var survey = new Survey.Model(surveyJSON);
survey.onComplete.add(this.sendDataToServer.bind(this));
survey.render("surveyElement", { model: survey });
survey.onAfterRenderSurvey.add(function(survey){
console.log("Hello world");
})
}