Solved

Response.write does not write a string on web page

Posted on 2009-07-09
2
238 Views
Last Modified: 2012-08-13
I got an error msg while doing a process on my website.

and i want to present that error msg to the user.

i am giving the whole error msg below.

when i am doing response.write then i am not getting the error msg string on the page.
any one could help me out here
this is the actual error msg
 
\"\0\" is an unexpected token. The expected token is \">\". Line 34176, position 29
 
 
 
and i am trying to do 
 
string r = "ErrorMsg = '\"\0\" is an unexpected token. The expected token is \">\". Line 34176, position 29.'";
 
 
        Response.Write(r);
 
and i am getting this as the output
 
ErrorMsg = '"

Open in new window

0
Comment
Question by:ziorrinfotech
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 3

Assisted Solution

by:Joep_Killaars
Joep_Killaars earned 20 total points
ID: 24820906
I get this as the message when I execute your code :

ErrorMsg = '"" is an unexpected token. The expected token is ">". Line 34176, position 29.'

The one thing I can think of is that \0 is being recognized as an 'End of string' character.  What is the textual output you want to write ? Why do you have \0 in your error string ?
0
 
LVL 39

Accepted Solution

by:
Pratima Pharande earned 30 total points
ID: 24820950
try this

  string r = @"ErrorMsg = \""\0\"" is an unexpected token. The expected token is \"">\"". Line 34176, position 29";


            Response.Write(r);
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I recently went through the process of creating a Calendar Control of events with the basis of using a database to keep track of the dates that are selectable, one requirement was to have the selected date pop-up in a simple lightbox.  At first this…
Today is the age of broadband.  More and more people are going this route determined to experience the web and it’s multitude of services as quickly and painlessly as possible. Coupled with the move to broadband, people are experiencing the web via …
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question