Default Values are not getting displayed when component is drag and dropped





I am pre-populating the multifield values in the dialog using listeners in classic ui. But when i drag and drop the component in the page, those values are not getting displayed. But when i open the dialog and click 'OK', then the values are getting displayed.


So what i need to do so that values will be displayed as soon as the component is dropped on the page.

Can someone help me on this.




Accepted Solutions (0)

Answers (3)

Answers (3)




@maheswariv26797 still using classic UI? 


Anyways to populate default values for a component on the page when you drag and drop, configuring default values in dialog will not suffice as it will only come into picture after author opens the dialog, if you want them to be displayed immediately after drag and drop, have to implement default cases in template either via sightly, sling model, wcmusepojo or JSP which ever you use for component templates.



Hi @maheswariv26797 ,


When you drag and drop the component, the dialog does not even exist yet. When you open it, it fills with the default values provided by you in the dialog definition, and then, once you close it, POSTs them to the JCR so that you can see the effect.

To actually initialize the component with values using listener we need to create a proper content template. You can check here hope it helps: