Server.HtmlDecode for windows services (Urgent)

  • Thread starter Thread starter Sonu Kapoor
  • Start date Start date
S

Sonu Kapoor

Hello,

does anybody knows the equilant of Server.HtmlDecode when
creating a windows service?

Thanks, Sonu
 
I think System.Web.HttpUtility.HtmlDecode, which is a static function,
should do the trick. HttpUtility is a pretty useful class for programs
which don't have access to a Server object like you do in ASP.Net

Karl
 
Hi Karl,

I get the following error when using this:

"HttpUtility" is not a member of "web".

Sonu
 
You don't have the System.Web.dll referenced in your project.

Unfortunately, System.dll actually has a System.Web namespace in it, which
is why the error is what it is. Simply reference System.Web.dll :)

Karl
 
Hello,

I imported the System.Web via the project properties
and thought that this should be enough. But it wasnt. I
have reference System.Web and it works now. Many thanks.

Sonu
 
Back
Top