Quantcast
Channel: ASP.NET AJAX + Ajax Control Toolkit (ACT)
Viewing all articles
Browse latest Browse all 5678

ASP.NET conditional ConfirmButtonExtender

$
0
0

I have a button on my page (with ajax ConfirmButtonExtender).

If on the page the user has selected over say, 1 million rows of data (this is calculated in the code-behind), when they then click on the the button, a pop up message will ask if they wanted to batch export the selection (i.e. Yes or Cancel).

So essentially, there are 2 possible scenarios.

1) Selection under 1 million rows.

Do NOT show the pop-up confirm message at all when click on the button - just run some codes in code-behind page. (i.e. Bypass the ConfirmButtonExtender msg).

2) Selection over 1 million rows.

A pop up message appears asking user to confirm if they'd like to batch export selection. User will select Yes or Cancel.

My question is - is it possible for the confirm message from ConfirmButtonExtender to be conditional (based on some calculation in the code-behind)?

How do I go about achieving this? Keep in mind that when user first clicks on the button, some codes will first need to run on code-behind to calculate the # of selections then decide whether to prompt the pop-up message.

Any ideas?


Viewing all articles
Browse latest Browse all 5678

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>