on 02-15-2019 11:07 AM
Hi,
I have a button inside IconTabFilter,when i click on that button it should navigate to the next IconTabFilter.
can anyone tell me how to do that.
Hi sai tharun,
You can check the UI5 library api reference for this controls, which has all the methods available to solve your issue.
https://ui5.sap.com/#/api/sap.m.IconTabBar/methods/setSelectedKey
Call the above method to set the selected key by passing the second icon tab key value.
BR,
Mahesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Sai Tharun this one
App.view.xml:
<IconTabBar id="idTopLevelIconTabBar">
<items>
<IconTabFilter text="{i18n>onePlus6TFilter}" key="1">
<Carousel>
<pages>
<Image src="https://spiderimg.amarujala.com/assets/images/2018/07/10/750x506/oneplus-6_1531206415.jpeg" height="600px"/>
<Image src="https://images.indianexpress.com/2018/06/759-25.jpg" height="600px"/>
</pages>
</Carousel>
<Toolbar>
<ToolbarSpacer/>
<Button text="{i18n>showBuyText}" type="Accept" press="onShowBuy"/>
</Toolbar>
<IconTabFilter text="{i18n>layoutCustomerFilter}" select="onShowBuy" selectedKey="2">
<MessageStrip type="Information" showIcon="true" text="All fields are mandatory"/>
</IconTabFilter>
App.controller.js:<br>
onShowBuy: function (oEvent) {
this.getView().byId("idTopLevelIconTabBar").setSelectedKey("2");
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Check this sample..
you are getting the button source and calling src.getSelectedKey(sKey) ==> Obviously this will not work right??
You need to get the reference of the IconTabBar and call getSelectedKey.
https://next.plnkr.co/edit/QM7WoaCueCsDjJ27?open=lib%2Fscript.js⪯view
BR,
Mahesh
HiSai Tharun,
I mean, you need to mark my answer as answered 😄 not yours as it is comment by you 🙂 Mahesh
I think you need to check the old answers not this one.. as I only commented here to your answer.
Comments cannot be marked as answered, only the answers will be marked as answered.. So you need to check my first answer.
Else it might be bug click on "Alert Moderator" and report the issue.
BR,
Mahesh
Hi mahesh,
I have tried that but what i want is navigation from one icontabfilter to another,not from one icontab to another.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sai,
I dont understand your query..
If you are having iicontabar then if you want to select one icon tab filter from another you need to call that method I mentioned..
But it might not call the icontabfilter selected event, so you need to put that code in a reusable function and call it along with the setSelectedKey method..
Or am I missing something? Posting code would be helpful.
BR
Mahesh
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.