Click here to Skip to main content
15,891,704 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Below is my code for Textchange but when i change my text nothing happens

VB
Private Sub DESIG_NAME_TextChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles DESIG_NAME.TextChanged
        JOB_PROFILE.Text = ""
End Sub


ASP.NET
 <td nowrap=""><asp:textbox id=DESIG_NAME runat="server" CssClass="TextBox_BorderWROla"  MaxLength="30" size="40" ReadOnly="True"> <INPUT class=CB_Pop onmousemove='return displayhand_onmousemove("DESIG_NAME_POP")'  id=DESIG_NAME_POP onclick="return DESIG_NAME_POP_onclick()"  type=button value=... name=DESIG_NAME_POP><font class="StarFnt">*</font></td>

AutopostBAck = "True"



Can anybody help me.
Posted
Updated 7-Jan-14 0:22am
v3
Comments
Nelek 7-Jan-14 6:22am    
Code blocks added

The server will not process any postbacks if the control is readonly[^].
 
Share this answer
 
Comments
Member 9410081 8-Jan-14 1:30am    
Ya My control is readonly.
So can u pls help in this case.
Jörgen Andersson 8-Jan-14 1:44am    
Simple, if you want the control to handle the textchanged event you need to remove the ReadOnly attribute.
The attribute is incompatible with the event.
Member 9410081 8-Jan-14 2:30am    
Thanks.
Member 9410081 8-Jan-14 3:58am    
When i change the readonly attribute to false ,then when i press Enter on textbox then only the event gets fired , after change nothing happens.

Is there any other solution if the Readonly attribute is True?
Jörgen Andersson 8-Jan-14 5:35am    
Is ViewState on?
you didn't give the reference of event in the textbox...

follow the code below

C#
<asp:textbox id="TextBox1" runat="server" ontextchanged="TextBox1_TextChanged" xmlns:asp="#unknown"></asp:textbox>



Hope it will helps you

Thanks
My blog: http://aspnetgeeks.blogspot.com/[^]
 
Share this answer
 
Comments
Member 9410081 7-Jan-14 6:39am    
Thanks.
Member 9410081 7-Jan-14 6:41am    
This isn't working any other option?
Arslan Elahi 7-Jan-14 6:44am    
have you put the event name on action tab in properties of the textbox?
Event name and reference name should be the same
this is the standard method.. it should be working .. you should check the constraints to make it successfull.....
Member 9410081 7-Jan-14 6:58am    
Thanks
Member 9410081 7-Jan-14 6:59am    
Both are Same.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900