I am using dreamweaver to build my first asp.net application, I am creating a form that has a dropdownlist of employees in the company. It is a dynamic dropdown list. What I am trying to do is to add a "please select" item into this dropdown list but I was not able to get it to work. It still defaults to the first item from the database. I've been trying to figure this out for couple days but no luck and I don't know what I did wrong, I hope that someone could help me out here. Here is the codes:
<script runat="server">
Sub Page_Load(Src As Object, E As EventArgs)
If NOT IsPostBack Then
Attendee1.DataSource = rsEmployees.DefaultView
Attendee1.DataTextField="fullName"
Attendee1.DataValueField="ID"
Attendee1.DataBind()
Attendee1.Items.Insert(0,"please select")
End If
End Sub
</script>
Inside Form tag, I have:
<asp:Drop ...
Go to the complete details ...
Found interesting? Add this to: