Click here to Skip to main content
15,912,977 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: Dynamic link button controls Pin
Abhijit Jana30-Jul-09 8:26
professionalAbhijit Jana30-Jul-09 8:26 
GeneralRe: Dynamic link button controls Pin
Ersan Ercek30-Jul-09 8:27
Ersan Ercek30-Jul-09 8:27 
GeneralRe: Dynamic link button controls Pin
Abhijit Jana30-Jul-09 9:01
professionalAbhijit Jana30-Jul-09 9:01 
GeneralRe: Dynamic link button controls Pin
Ersan Ercek30-Jul-09 9:17
Ersan Ercek30-Jul-09 9:17 
GeneralRe: Dynamic link button controls Pin
Ersan Ercek30-Jul-09 9:28
Ersan Ercek30-Jul-09 9:28 
GeneralRe: Dynamic link button controls Pin
Abhijit Jana30-Jul-09 9:31
professionalAbhijit Jana30-Jul-09 9:31 
GeneralRe: Dynamic link button controls Pin
Ersan Ercek30-Jul-09 9:32
Ersan Ercek30-Jul-09 9:32 
QuestionSelectedIndexChanged Event for Dropdownlist AJAX Pin
Ridge Howison30-Jul-09 7:06
Ridge Howison30-Jul-09 7:06 
Hello,

Thank you for reading. Here is my situation. I have an UpdatePanel and within in I have 2 dropdownlists.   I want to show the second ddlist only when a specific value is chosen in dropdownlist1. I used Javascript/label etc on the selectedIndexChanged event but still does not work. The event gets fired and I stepped thru the code with no problems but it does not render on screen. Code snippet below. All help is wonderfully,gratefully and thankfully appreciated.

Front End

<asp:UpdatePanel ID="updPanel1" runat="server">
            <ContentTemplate>
         <asp:DropDownList ID="ddlTest1" runat="server" AutoPostBack="true" OnSelectedIndexChanged="ddlTest1_IndexChanged">
            <asp:ListItem Value="" Text="Select one"></asp:ListItem>
            <asp:ListItem Value="Matt" Text="Matt"></asp:ListItem>
            <asp:ListItem Value="Robin" Text="Robin"></asp:ListItem>
            </asp:DropDownList>
            <asp:DropDownList ID="ddlTest2" runat="server" style="visibility:hidden;display:none;">
            <asp:ListItem Text="Select One" Value=""></asp:ListItem>
            <asp:ListItem Text="Tom" Value="Tom"></asp:ListItem>
            <asp:ListItem Text="John" Value="John"></asp:ListItem>
           
      </asp:DropDownList>
</ContentTemplate>
            </asp:UpdatePanel>

And the Codebehind is as follows:

Protected Sub ddlTest1_IndexChanged(ByVal sender As Object, ByVal e As EventArgs)
            If ddlTest1.SelectedValue = "Robin" Then

                  Dim script As String = "<script type='text/javascript'>var elem=document.getElementById('" & Me.ddlTest2.ClientID & "');elem.style.visibility='visible';elem.style.display='block';</script>
        
Page.ClientScript.RegisterClientScriptBlock(Me.GetType(), "newKeyVal", script, True)
                 
            Else
                  Dim script As String = "<script type='text/javascript'>var elem=document.getElementById('" & Me.ddlTest2.ClientID & "');elem.style.visibility='hidden';elem.style.display='block';</script>"
                  Page.ClientScript.RegisterClientScriptBlock(Me.GetType (), "newKeyVal", script, True)
                 
            End If

      End Sub
AnswerRe: SelectedIndexChanged Event for Dropdownlist AJAX Pin
Abhijit Jana30-Jul-09 8:14
professionalAbhijit Jana30-Jul-09 8:14 
AnswerRe: SelectedIndexChanged Event for Dropdownlist AJAX Pin
Abhishek Sur30-Jul-09 8:59
professionalAbhishek Sur30-Jul-09 8:59 
QuestionSystem.Runtime.InteropServices.COMException: Cannot activate application Pin
vikash_singh30-Jul-09 4:56
vikash_singh30-Jul-09 4:56 
AnswerRe: System.Runtime.InteropServices.COMException: Cannot activate application Pin
Abhishek Sur30-Jul-09 5:00
professionalAbhishek Sur30-Jul-09 5:00 
GeneralRe: System.Runtime.InteropServices.COMException: Cannot activate application Pin
vikash_singh30-Jul-09 5:33
vikash_singh30-Jul-09 5:33 
GeneralRe: System.Runtime.InteropServices.COMException: Cannot activate application Pin
vikash_singh30-Jul-09 6:56
vikash_singh30-Jul-09 6:56 
GeneralRe: System.Runtime.InteropServices.COMException: Cannot activate application Pin
Abhishek Sur30-Jul-09 9:10
professionalAbhishek Sur30-Jul-09 9:10 
GeneralRe: System.Runtime.InteropServices.COMException: Word has encountered the problem Pin
vikash_singh30-Jul-09 23:16
vikash_singh30-Jul-09 23:16 
GeneralRe: System.Runtime.InteropServices.COMException: Word has encountered the problem Pin
vikash_singh31-Jul-09 2:23
vikash_singh31-Jul-09 2:23 
AnswerRe: System.Runtime.InteropServices.COMException: Word has encountered the problem Pin
vikash_singh31-Jul-09 2:24
vikash_singh31-Jul-09 2:24 
QuestionMVC action loading view page twice Pin
marky77730-Jul-09 4:41
marky77730-Jul-09 4:41 
AnswerRe: MVC action loading view page twice Pin
Claies30-Jul-09 7:18
Claies30-Jul-09 7:18 
AnswerRe: MVC action loading view page twice Pin
Speto26-Sep-09 9:49
professionalSpeto26-Sep-09 9:49 
QuestionRemoving a object instance completely out of memory. Pin
Ashutosh Trivedi30-Jul-09 3:02
Ashutosh Trivedi30-Jul-09 3:02 
AnswerRe: Removing a object instance completely out of memory. Pin
Abhishek Sur30-Jul-09 3:18
professionalAbhishek Sur30-Jul-09 3:18 
GeneralRe: Removing a object instance completely out of memory. Pin
Ashutosh Trivedi30-Jul-09 5:09
Ashutosh Trivedi30-Jul-09 5:09 
AnswerRe: Removing a object instance completely out of memory. Pin
Abhishek Sur30-Jul-09 9:26
professionalAbhishek Sur30-Jul-09 9:26 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.