Hi, sorry still learning how to do things in asp.
Basically I have a form that I set up using the insert template in visual studio.
where the code looks like this
<InsertItemTemplate>
<table class="style15">
<tr>
<td class="style18">
SitesAffected:
</td>
<td class="style16">
Description:</td>
</tr>
<tr>
<td class="style19">
<asp:CheckBoxList ID="SitesCheckBoxList" runat="server" AutoPostBack="True"
Text='<%# Bind("SitesAffected") %>'>
<asp:ListItem>Manchester</asp:ListItem>
<asp:ListItem>Newcastle</asp:ListItem>
</asp:CheckBoxList>
</td>
<td class="style17">
<asp:TextBox ID="DescriptionTextBox" runat="server" Height="146px"
Text='<%# Bind("Description") %>' Width="239px" />
</td>
</tr>
<tr>
<td class="style20">
Creator:</td>
<td>
SendTo:</td>
</tr>
<tr>
<td class="style20">
<asp:TextBox ID="CreatorTextBox" runat="server" Text='<%# Bind("Creator") %>' />
</td>
<td>
<asp:TextBox ID="SendToTextBox" runat="server" Text='<%# Bind("SendTo") %>' />
</td>
</tr>
<tr>
<td class="style20">
TechnicianDealing:</td>
<td>
BulletinType:</td>
</tr>
<tr>
<td class="style20">
<asp:TextBox ID="TechnicianDealingTextBox" runat="server"
Text='<%# Bind("TechnicianDealing") %>' />
</td>
<td>
<asp:DropDownList ID="CriticalBx" runat="server" AutoPostBack="True"
Text='<%# Bind("BulletinType") %>'
onselectedindexchanged="CheckBoxList1_SelectedIndexChanged">
<asp:ListItem>High</asp:ListItem>
<asp:ListItem>Critical</asp:ListItem>
<asp:ListItem>Change</asp:ListItem>
</asp:DropDownList>
</td>
</tr>
<tr>
<td class="style20">
TextSent:
</td>
<td>
DateTime:</td>
</tr>
<tr>
<td class="style20">
<asp:CheckBoxList ID="TextSentCheckList" runat="server" AutoPostBack="True"
Text='<%# Bind("TextSent") %>'>
<asp:ListItem>Yes</asp:ListItem>
<asp:ListItem>No</asp:ListItem>
</asp:CheckBoxList>
</td>
<td>
<asp:TextBox ID="DateTimeTextBox" runat="server"
Text='<%# Bind("DateTime") %>' />
</td>
</tr>
</table>
<br />
<asp:Button ID="InsertButton" runat="server" CausesValidation="True"
CommandName="Insert" Text="Send" onclick="InsertButton_Click" />
<asp:Button ID="InsertCancelButton" runat="server"
CausesValidation="False" CommandName="Cancel" Text="Cancel"
style="margin-bottom: 0px" />
</InsertItemTemplate>
What I want to do is put in a IF statement for a drop down list where if a certain value is selected it does something.
However in the vb page it doesn't recognise the drop down list I have, however if I move the drop down list outside the template it does recognise it.
Does anyone know how I can do this but keep the drop down list in the template?
I hope this makes sense
Thanks