Click here to Skip to main content
15,910,878 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralIpn in online Payment Pin
Member 46590018-Apr-08 19:00
Member 46590018-Apr-08 19:00 
GeneralUser controls as output for "copy this script for your website" blocks Pin
Christopher Duncan8-Apr-08 17:41
Christopher Duncan8-Apr-08 17:41 
GeneralRe: User controls as output for "copy this script for your website" blocks Pin
led mike9-Apr-08 6:10
led mike9-Apr-08 6:10 
GeneralRe: User controls as output for "copy this script for your website" blocks Pin
Christopher Duncan9-Apr-08 6:28
Christopher Duncan9-Apr-08 6:28 
GeneralRe: User controls as output for "copy this script for your website" blocks Pin
led mike9-Apr-08 6:34
led mike9-Apr-08 6:34 
GeneralRe: User controls as output for "copy this script for your website" blocks Pin
Christopher Duncan9-Apr-08 6:41
Christopher Duncan9-Apr-08 6:41 
GeneralRe: User controls as output for "copy this script for your website" blocks Pin
led mike9-Apr-08 6:58
led mike9-Apr-08 6:58 
GeneralAjax Postback issue Pin
engsrini8-Apr-08 15:29
engsrini8-Apr-08 15:29 
Hi,

I am using asp.net 2.0, trying to create chat application. I am copying the user entered text to a asp.net textbox using the following java script function

    document.getElementById("TextBox1").value= "chat message entered by user";
userid = location.search.substring( 1, location.search.length );
url = 'Chat.aspx?action=chatmsg&u=' + userid ;

req = getAjax();

req.onreadystatechange = function(){
    if( req.readyState == 4 && req.status == 200 ) {
        updateAll();
    }

}
req.open( 'GET', url, true );
req.send( null );

with the following asp.net textbox definition


<asp:TextBox ID="TextBox1" runat="server" AutoPostBack =false ReadOnly=false  ></asp:TextBox>


and i am handling the ajax postback @ chat.aspx like this


chat.aspx's page load method
protected void Page_Load(object sender, System.EventArgs e)
{
            string chatMsg = TextBox1.Text;
}



But the problem is i always see the TextBox1.Text as empty instead of "chat message entered by user" which i copied thru javascript function, but i can able to see in internet explorer that the TextBox1.Text gets updated when i call postback.

I put alert before calling chat.aspx like this
alert("TextBox1 text VALUE =  "+document.getElementById("TextBox1").value);

it is also showing the updated value, but i could not able to see in the codebehind (page_load method)

But if i do any postback thru button click, i can able to see the updated vlaue of TextBox1.Text

Can somebody help me out.. what went wrong on this?

Thanks
Srini
GeneralRe: Ajax Postback issue Pin
Herman<T>.Instance9-Apr-08 21:58
Herman<T>.Instance9-Apr-08 21:58 
Generalstarterkit Pin
strawberrysh8-Apr-08 8:08
strawberrysh8-Apr-08 8:08 
GeneralRe: starterkit Pin
Christian Graus8-Apr-08 11:17
protectorChristian Graus8-Apr-08 11:17 
QuestionTreeView Web Control using ASP.NET 1.1 Pin
Suneet Singh Rana8-Apr-08 7:37
professionalSuneet Singh Rana8-Apr-08 7:37 
GeneralRe: TreeView Web Control using ASP.NET 1.1 Pin
Christopher Duncan8-Apr-08 17:46
Christopher Duncan8-Apr-08 17:46 
GeneralProgramatically defining css Pin
dptalt8-Apr-08 7:24
dptalt8-Apr-08 7:24 
GeneralRe: Programatically defining css Pin
Christian Graus8-Apr-08 11:19
protectorChristian Graus8-Apr-08 11:19 
GeneralRe: Programatically defining css Pin
Christopher Duncan8-Apr-08 17:49
Christopher Duncan8-Apr-08 17:49 
GeneralRe: Programatically defining css Pin
Christian Graus8-Apr-08 18:20
protectorChristian Graus8-Apr-08 18:20 
GeneralRe: Programatically defining css Pin
Christopher Duncan9-Apr-08 3:02
Christopher Duncan9-Apr-08 3:02 
GeneralInternet Explorer API Question... Pin
Edmundisme8-Apr-08 7:23
Edmundisme8-Apr-08 7:23 
Generali am using .net2008 on vista whree i sendind SMTP mail but error is produce :- Cannot get IIS pickup directory Pin
Piyush Vardhan Singh8-Apr-08 5:19
Piyush Vardhan Singh8-Apr-08 5:19 
AnswerRe: i am using .net2008 on vista whree i sendind SMTP mail but error is produce :- Cannot get IIS pickup directory Pin
Jesse Squire8-Apr-08 5:53
Jesse Squire8-Apr-08 5:53 
GeneralRe: i am using .net2008 on vista whree i sendind SMTP mail but error is produce :- Cannot get IIS pickup directory Pin
Piyush Vardhan Singh8-Apr-08 8:13
Piyush Vardhan Singh8-Apr-08 8:13 
AnswerRe: i am using .net2008 on vista whree i sendind SMTP mail but error is produce :- Cannot get IIS pickup directory Pin
Jesse Squire8-Apr-08 8:25
Jesse Squire8-Apr-08 8:25 
General2 languages in website Pin
strawberrysh8-Apr-08 5:16
strawberrysh8-Apr-08 5:16 
GeneralRe: 2 languages in website Pin
Jesse Squire8-Apr-08 5:40
Jesse Squire8-Apr-08 5:40 

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.