Archive for the ‘ASPX Web Controls’ Category
How to use FileUpload with UpdatePanel
Posted by: admin in ASP.Net, ASPX Web Controls on September 21st, 2011
Common problem with the aspx web developers when using the FileUpload within UpdatePanel is it simply does not work, the file you want to upload would not get into the web server since the UpdatePanel control is in partial postback while the FileUpload needs to be a full postback.
So, to make the UpdatePanel control a full postback is simply add a Triggers. see the example below
-
<asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="conditional">
-
<Triggers>
-
<asp:PostBackTrigger ControlID="Button1" />
-
</Triggers>
-
<ContentTemplate>
-
<ews:DatePicker ID="DatePicker1" runat="server" UsingUpdatePanel="True"
-
OnSelectionChanged="DatePicker1_SelectionChanged" /><br />
-
<asp:Label ID="Label1" runat="server"></asp:Label><br /><br />
-
<asp:FileUpload ID="FileUpload1" runat="server" />
-
<asp:Button ID="Button1" runat="server" Text="Upload" OnClick="Button1_Click" />
-
</ContentTemplate>
-
</asp:UpdatePanel>
How to search string in the DropdownList Control
Posted by: admin in ASP.Net, Dropdown List on October 24th, 2010
-
-
function searchString(sText as String)
-
dim li as ListItem
-
-
li = dropdownlist1.Items.FindByValue(sText);
-
-
if li isnot nothing then
-
-
li.selected = True
-
-
end if
-
-
-
end function
Dropdown List event not firing
Posted by: admin in .NET, Dropdown List on June 18th, 2010
Just make sure to set the AutoPostBack = true.