You have to specify the AutoPostBack property of the text box to true.
In aspx,
<asp:textbox id="txtTest" autopostback="true" runat="server" ontextchanged="txtTest_Changed" xmlns:asp="#unknown"></asp:textbox>
In code-behind,
protected void txtTest_Changed(object sender, EventArgs e)
{
}