This is a migrated thread and some comments may be shown as answers.

Javascript not loaded on postback

1 Answer 88 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
navyateja
Top achievements
Rank 1
navyateja asked on 14 Jan 2015, 09:03 PM
Hi,

I have a user control with a combox on it. There is some javascript defined on the user control.

<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="RSSA.ascx.cs"
Inherits="Auto.RSSA" %>

<script type="text/javascript">
 
      function Function1() {
}
</script>
<div class="test">
<telerik:RadComboBox ID="SSSL" runat="server" AutoPostBack="True" OnSelectedIndexChanged="SSSL_SelectedIndexChanged" OnClientSelectedIndexChanged="Function1" Width="300px" Filter="Contains">
</telerik:RadComboBox>
</div>


A page has the usercontrol with in updatepanel. the usercontrol is not visible on pageload. the control is made visible after a postback. the radcombox but the javascript is not being loaded. Function1 is undefined.

Any help is appreciated.

Thanks,
TJ

1 Answer, 1 is accepted

Sort by
0
Robert Helm
Top achievements
Rank 1
answered on 14 Jan 2015, 09:54 PM
Have you tried moving the JavaScript out of the usercontrol and into the page?
Tags
ComboBox
Asked by
navyateja
Top achievements
Rank 1
Answers by
Robert Helm
Top achievements
Rank 1
Share this question
or