Solved

Response.write does not write a string on web page

Posted on 2009-07-09
2
234 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
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

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

This article discusses the ASP.NET AJAX ModalPopupExtender control. In this article we will show how to use the ModalPopupExtender control, how to display/show/call the ASP.NET AJAX ModalPopupExtender control from javascript, how to show/display/cal…
Sometimes in DotNetNuke module development you want to swap controls within the same module definition.  In doing this DNN (somewhat annoyingly) swaps the Skin and Container definitions to the default admin selections.  To get around this you need t…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

746 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

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now