Response.write tool

C

Chris

Hi,

Is there a macro or add-on to Visual Studio.net that can easily
convert HTML to response.write statements with any "s escaped?
Handling <%=string%> inline script as concatenation would be helpful
too as I have an old ASP site to update that uses a lot of these in
functions. So you could highlight multiple lines like the following in
Visual Studio

<H2>An error has occured</H2>
<SPAN class="error"><%=sError%></SPAN>

click convert and get

Response.write("<H2>An error has occured</H2>\n") ;
Response.write("<SPAN class=\"error\">" + sError + "</SPAN>\n") ;

in C# or the equivalent VB etc,. This must be such a common task that
not having to paste Response.write and closing ) ; on every line would
make this very useful.

I don't know much about macros but could I create one to do this?
 
C

Chris

I really need a C# .Net version but I could use this to get a step closer.
Thanks for that.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,780
Messages
2,569,611
Members
45,271
Latest member
BuyAtenaLabsCBD

Latest Threads

Top