Tip #74: Did you know…How to Add and Remove AJAX Extenders in Visual Studio 2008 Designer?

Tip#62 showed you how to add an AJAX Control Toolkit to your Toolbox.

Once you have the toolkit here is how you proceed:

1. Switch to Design View of the page and drag drop ScriptManager control from the AJAX Extensions tab of toolbox to the designer.

2. Drag drop an asp button control to the designer to which you would want to add the extender.

4. Select the button control and click on the Smart Tag. This will bring up the   

 Add Extender.. option.

Add Extender

5. Now click on Add Extender….This will bring up the Extender Wizard as shown below. Pick ConfirmButtonExtender and click Ok. Alternatively you can drag drop the ConfirmationButtonExtender from your toolbox on to the button control on your designer.


It is interesting to note that on adding an extender control, Visual Studio’s property grid displays the extender properties. Set the Confirm Text property for the extender to be      “Are you sure?”.

6. Run the page and see that on clicking the button, you get a confirmation box as shown below.


7. To remove, select the control and bring up the Smart Tag and click on the Remove Extender option in the Smart Task Menu. This will bring up the Remove Extender dialog.

Click Remove and click Ok to remove the extender from your button control.



Reshmi Mangalore

SDET, Visual Web Developer