cancel
Showing results for 
Search instead for 
Did you mean: 

Help on HTMLB TabStrip

Former Member
0 Kudos
56

Hi all,

I ve created an IVIEW with a tabstrip and 4 tabstrip items.

And i ve some input fields and buttons in each tabstrip items.

What happens is.. when i am entering data and clicking the button.. the page gets refreshed and showing the content of the first tabstrip item which is the default selection.

I was trying to get the control of the tabstrip in my event handling method of the button in my jspdynpage and set the selection of tabstrip item to current tabstrip item. but still the iview gets refreshed and showing the first tabstrip item.

Please help me to solve this problem.

Thanks & Regards,

Siva

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Siva,

<b>Try to store the index of the selected tab in some bean object. Then in your jsp file retreive it and set the selection of tabstrip to this index.</b> You have to do this in your jsp file, because even if you set it in your event handler, it will be overwritten when the jsp file is rendered. So do it in your jsp file.

Hope this helps.

Ranjith

Former Member
0 Kudos

thanks Ranjith..

I ll try and reply u back

bye

Former Member
0 Kudos

Ranjith,

I am not able to get the control of the tabstrip in my event handler method.

i tried in two ways to get the index of the currently selected tabstrip item

method 1:

TabStrip myTabStrip = (TabStrip) getComponentByName("myTabStrip");

if(myTabStrip!=null){

TabStripItem tabStripItem = myTabStrip.getItem(2);

index = tabStripItem .getIndex();

}

Method 2:

TabStripItem myTabStripItem = (TabStripItem) getComponentByName("myTabStripItem2");

if(myTabStripItem!=null){

index = myTabStripItem .getIndex();

}

Can u help me out to fix the problem.

Thanks and Regards,

Siva

Both the case its not working... its taking the default value of class variable index that's 0.

Former Member
0 Kudos

Hi Ranjith,

I solved it..

myTabStrip.getSelection command gives the currently selected tabstrip item's index.. and i used that to set in bean class.

now its perfectly working

Thanks a lot yaar.

by the way u r from which place?

siva

Former Member
0 Kudos

Hi Siva,

Always remember to reward helpful answers (the sdn way of saying 'Thanks').

>by the way u r from which place?

You want to know my native place or the place where i am working right now?

Ranjith

Former Member
0 Kudos

hi ranjith,

Good morning

I gave the pts to u already.

hey just like that i asked ur place.

i am in blore now..native TN..

wat abt u?

Thanks & regards,

Siva

Former Member
0 Kudos

Hi Siva,

Very Good Morning to you also.

I'm a Keralite working now in Chennai.

Regards

Ranjith

Answers (0)