Skip to Content

SAPUI5 - Set default Variant


I have a Fiori application and have a conroller.js file. I also created a shared varaint.

I am strugging with setting the created variant as a default variant for all other users.

I saw class - class sap.ui.comp.smartvariants.SmartVariantManagement in Demo Kit but not sure what all methods will help. Did many trial and error, no luck so far.

setting variant should be in onBeforeRendering or OnInit ? Any help with some psedocode is appreciated.

Help !


Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Feb 28, 2018 at 10:06 PM

    Hello Tanveer Shaikh,

    Thank you for your post. It seems that you've chosen the wrong tag for your question which decreases its chances to be answered. In the future, please submit your question with the right tag.

    You can learn more about tags at and browse all existing tags here:

    For general information and tips about asking questions in the community, please visit this page:

    I've removed the wrong tags for this question for now. Please post according to the guidelines provided above. In case you have any additional questions regarding the SAP Community, please reach out to scnmoderators (at ) sap (dot) com.

    Thank you for your understanding.

    Bruno Lucattelli
    SAP Community Moderator

    Add comment
    10|10000 characters needed characters exceeded