TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Fakir Ahmet
NA
2
633
I can not access in the second view elements(txtB) reference
May 5 2017 11:14 AM
I can not access in the second view elements(textBoxs) reference . why it could be
<body onload="show()" >
<form id="form1" runat="server">
<div>
<asp:MultiView ID="MultiView1" runat="server">
<asp:View ID="View1" runat="server">
<table class="auto-style1">
<tr>
<td class="baslik">Adi </td>
<td>
<asp:TextBox ID="a1" runat="server" ClientIDMode="Static" Width="300px"></asp:TextBox>
</td>
</tr>
<tr>
<td class="auto-style2">Soyadi</td>
<td class="auto-style3" id="a2">
<asp:TextBox ID="a2" runat="server" ClientIDMode="Static" Width="300px"></asp:TextBox>
</td>
</tr>
<tr>
<td class="auto-style6">Memleket</td>
<td class="auto-style7">
<asp:TextBox ID="a3" runat="server" ClientIDMode="Static" TextMode="MultiLine" Width="300px"></asp:TextBox>
</td>
</tr>
</table>
</asp:View>
<asp:View ID="View2" runat="server">
<table class="auto-style1">
<tr>
<td class="baslik">Meslek</td>
<td>
<asp:TextBox ID="b1" runat="server" ClientIDMode="Static" Width="300px"></asp:TextBox>
</td>
</tr>
<tr>
<td class="auto-style4">Mezuniyet</td>
<td class="auto-style5">
<asp:TextBox ID="b2" runat="server" ClientIDMode="Static" OnTextChanged="TextBox5_TextChanged" Width="300px"></asp:TextBox>
</td>
</tr>
<tr>
<td class="baslik">Brans</td>
<td>
<asp:TextBox ID="b3" runat="server" ClientIDMode="Static" TextMode="MultiLine" Width="300px"></asp:TextBox>
</td>
</tr>
</table>
</asp:View>
</asp:MultiView>
</div>
<asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="1. Asama" />
<asp:Button ID="Button2" runat="server" OnClick="Button2_Click" Text="2. Asama" />
</form>
</body>
Javascript code
function show() {
var txt = new Array();
var alan = ['a1','a2','a3','b1','b2','b3'];
for (var i = 0; i < alan.length; i++) {
txt[i]=document.getElementById(alan[i]);
txt[i].addEventListener("keyup", wsss, true);
}
alert(txt.length);
}
function wsss(e){
alert("Mesaj"); // this method not work at the second view elements(textBox)
}
Reply
Answers (
0
)
Monitor Progress of Long Running ASMX Web Service ?
Can someone explain me the code to delete data and updates