Wizards is a control that provides users with an infrastructure that presents a series of steps. It facilitates navigation settings. Almost all appearance features of this control can be customized through styles and templates, including various buttons and links, titles and headers and footers, toolbar and steps.
The following is an example of today's situation:
First, add a wizard control. First, select a suitable style, and then open "Add/Remove wizardsteps Editor" to add the following five parts:
The basic information bar displays:
The text box IDs are tbnname and tbnpws.
Detailed information:
The province is followed by a dropdownlist control with ID: ddldf. We will add several provinces in the edit item below. Whether to disclose the details. The following is a radiobuttonlist control with the ID rdbgk:
Hobbies:
Here there are multiple checkboxes, which are very simple. Default ID.
Member grade:
The member level is also a dropdownlist control with the ID of ddldj. Then we can add several member options in the edit item.
Completed:
There is nothing to introduce here, which is very simple.
Background code:
Public partial class kongjian17: system. web. UI. page {// <summary> /// wizard control /// </Summary> /// <Param name = "sender"> </param> // <Param name = "E"> </param> protected void page_load (Object sender, eventargs e) {} protected void wizard1_finishbuttonclick (Object sender, wizardnavigationeventargs e) {string name = "Dear:" + tbname. text; response. write ("<SCRIPT> alert ('" + name + "thank you for registering') </SCRIPT> ") ;} Protected void wizard1_activestepchanged (Object sender, eventargs e) {lblname. Text = tbname. Text; // directly corresponds to the text box or drop-down list. Lblpws. TEXT = tbpws. text; If (rdbgk. selectedvalue = "no") {lblsf. TEXT = "Detailed information hidden by the user"; lblpws. visible = false;} else {lblsf. TEXT = "province:" + ddlsf. selectedvalue; lblphoto. TEXT = "Tel:" + tbpphoto. text;} checkboxlist CBl = (checkboxlist) MB. contenttemplatecontainer. findcontrol ("Chk"); For (INT I = 0; I <CBl. items. count; I ++) {If (CBL. items [I]. selected) {label LBL = new label (); LBL. id = "LBL" + I; LBL. TEXT = CBl. items [I]. text + "<br>"; Ph. controls. add (LBL );}}}}
The following page is displayed:
As for the specific demonstration effect, we will not present it here. Haha, it's similar to the above design, and you will understand it by yourself.
Of course, you can still add more interesting functions to the template. Due to space issues, I will not introduce them much. Let's explore them by yourself.