We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

OnItemSelect

I'm using the TabStrip item and would like to add an "alert" box question to open when the user clicks and item and prevent it's posting back if the user does not confirm. I tried the following:

ClientOnItemSelect="return confirm('Are you sure you want to DELETE this LINK between the Workforce record and the Student Record?');"

I have the autopostback set to true, and it is posting without invoking the java script "confirm".

Any ideas how I can implement this functionality?

Thanks,

James.

4 Replies

JK James Knowlton May 19, 2010 02:10 AM UTC

Ok, Mostly solved this one myself, I simply put the "return confirm("xxx"); in a function and pointed the ClientOnItemSelect="functionName()"

However this introduced a new problem, if I click "Cancel" on the confirm popup the tabstripitem remains "selected" (which is ok by itself) but if I click on it again it doesn't perform a post back, or fire the ClientOnItemSelect function.

Obviously the user could click the tabstripitem, cancel the confirm box and then change their mind and want to click the tabstrip item again. I want the confirm box to reappear but then beable to confirm the selection and have the associated tabstripitem code execute.

So, anybody know why a second "click" doesn't cause either the function to execute or the postback to occur?

Thanks,

James.



LK Lakxman Kumar C Syncfusion Team May 20, 2010 02:27 PM UTC

Hi James,

Thank you for your interest in Syncfusion Products.

This issue reported by you is suspected to be a defect and we have forwarded this to our Development Team for more analysis.

In addition to our Community Forums, we have other customized support avenues like our Direct Trac Developer Support System https://www.syncfusion.com/account/login?ReturnUrl=%2fsupport%2fdirecttrac%2fincidents and we hope you will take advantage of this system as well.

Regards,
Lakxman Kumar C


JK James Knowlton May 20, 2010 07:37 PM UTC

I didn't consider it a bug, just a feature that wasn't what I needed and hoped I could adjust. I guess it kind of makes sense what is the point of posting back to the server for a tab that is already displayed.

I managed a work around (though I still prefer using the tabstrip) by adding a tool bar to each multi-page attached to the tabstrip and it accomplishes the same thing just a little mor combersome since I need a unique toolbar for each page where the menu worked for all.

Thanks,

James.


LK Lakxman Kumar C Syncfusion Team May 21, 2010 01:01 PM UTC

Hi James,

We are glad that you found an alternative way for achieving your requirement. Please do let us know if you have any other queries.

Thank you for your participation in Syncfusion’s Community Forums.

Regards,
Lakxman Kumar C

Loader.
Live Chat Icon For mobile
Up arrow icon