Showing posts with label services. Show all posts
Showing posts with label services. Show all posts

Saturday, March 31, 2012

Server side error

Im trying to get my first aspx page working to no avail.
Im using Visual Studio .Net and when you start web services it gives you a short Hello World program to test the server with. When i try to run it all i get is the following error message.

Unable to start debugging on server.
Server side error occured on sending debug HTTP request.

I have tried all the procedures recommended on the Microsoft error page it sends you to with no luck at all.

Anything im missing?

IIS is installed.hello, make sure IIS is on, and ke sure u have give permission to ASPNET account for the folder in which the aspx page is in !!!
Ive set the asp account to administrator access and still the same error.

For some reason unknown to me my system is running fat32. Is this a problem at all?
administrator is something and aspnet account is something else, maybe this system is makingu troubles !!!!

Thursday, March 29, 2012

Server Side Time Out in c#

Hi

I have an ASP.NET site that uses web services for security. I have two
servers running the same service. Provided the servers are running I am
able to run a check script and swap servers depending on whether the
service is running properly. This works fine if just IIS has fallen
over.

The problem is that if the server is switched off, the ASP.NET code
continues to search for the server and leaves the application hanging.

Is is possible to add a timeout to the server-side code, so that after
say 5 seconds it stops searching for the server and uses the
alternative one?

Thanks

JaredI found a way to get round this. The web service has a Timeout already,
you just need to set it. I am not sure if every type of object has a
Timeout setting.

e.g.
WebService1.Security entsec = new WebService1.Security();

entsec.Timeput = 1000;
string entsecCheck = entsec.CommsCheck([password]);

This will time out after 1 second if the server is turned off.

Jared

Jared wrote:

Quote:

Originally Posted by

Hi
>
I have an ASP.NET site that uses web services for security. I have two
servers running the same service. Provided the servers are running I am
able to run a check script and swap servers depending on whether the
service is running properly. This works fine if just IIS has fallen
over.
>
The problem is that if the server is switched off, the ASP.NET code
continues to search for the server and leaves the application hanging.
>
Is is possible to add a timeout to the server-side code, so that after
say 5 seconds it stops searching for the server and uses the
alternative one?
>
Thanks
>
Jared

Server Side Time Out in c#

Hi
I have an ASP.NET site that uses web services for security. I have two
servers running the same service. Provided the servers are running I am
able to run a check script and swap servers depending on whether the
service is running properly. This works fine if just IIS has fallen
over.
The problem is that if the server is switched off, the ASP.NET code
continues to search for the server and leaves the application hanging.
Is is possible to add a timeout to the server-side code, so that after
say 5 seconds it stops searching for the server and uses the
alternative one?
Thanks
JaredI found a way to get round this. The web service has a Timeout already,
you just need to set it. I am not sure if every type of object has a
Timeout setting.
e.g.
WebService1.Security entsec = new WebService1.Security();
entsec.Timeput = 1000;
string entsecCheck = entsec.CommsCheck([password]);
This will time out after 1 second if the server is turned off.
Jared
Jared wrote:
> Hi
> I have an ASP.NET site that uses web services for security. I have two
> servers running the same service. Provided the servers are running I am
> able to run a check script and swap servers depending on whether the
> service is running properly. This works fine if just IIS has fallen
> over.
> The problem is that if the server is switched off, the ASP.NET code
> continues to search for the server and leaves the application hanging.
> Is is possible to add a timeout to the server-side code, so that after
> say 5 seconds it stops searching for the server and uses the
> alternative one?
> Thanks
> Jared

Thursday, March 22, 2012

Server.HtmlDecode for windows services (Urgent)

Hello,
does anybody knows the equilant of Server.HtmlDecode when
creating a windows service?
Thanks, SonuI 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
MY ASP.Net tutorials
http://www.openmymind.net/
"Sonu Kapoor" <sonukapoor@.gmail.com> wrote in message
news:18a401c4bc81$7f99de90$a601280a@.phx.gbl...
> Hello,
> does anybody knows the equilant of Server.HtmlDecode when
> creating a windows service?
> Thanks, Sonu
Hi Karl,
I get the following error when using this:
"HttpUtility" is not a member of "web".
Sonu

>--Original Message--
>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
>--
>MY ASP.Net tutorials
>http://www.openmymind.net/
>
>"Sonu Kapoor" <sonukapoor@.gmail.com> wrote in message
>news:18a401c4bc81$7f99de90$a601280a@.phx.gbl...
when
>
>.
>
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
MY ASP.Net tutorials
http://www.openmymind.net/
"Sonu Kapoor" <sonukapoor@.gmail.com> wrote in message
news:18ba01c4bc87$fde97980$a601280a@.phx.gbl...
> Hi Karl,
> I get the following error when using this:
> "HttpUtility" is not a member of "web".
> Sonu
>
> static function,
> class for programs
> ASP.Net
> when
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

>--Original Message--
>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
>--
>MY ASP.Net tutorials
>http://www.openmymind.net/
>
>"Sonu Kapoor" <sonukapoor@.gmail.com> wrote in message
>news:18ba01c4bc87$fde97980$a601280a@.phx.gbl...
in
>
>.
>

Server.HtmlDecode for windows services (Urgent)

Hello,

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

Thanks, SonuI 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

--
MY ASP.Net tutorials
http://www.openmymind.net/

"Sonu Kapoor" <sonukapoor@.gmail.com> wrote in message
news:18a401c4bc81$7f99de90$a601280a@.phx.gbl...
> Hello,
> does anybody knows the equilant of Server.HtmlDecode when
> creating a windows service?
> Thanks, Sonu
Hi Karl,

I get the following error when using this:

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

Sonu

>--Original Message--
>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
>--
>MY ASP.Net tutorials
>http://www.openmymind.net/
>
>"Sonu Kapoor" <sonukapoor@.gmail.com> wrote in message
>news:18a401c4bc81$7f99de90$a601280a@.phx.gbl...
>> Hello,
>>
>> does anybody knows the equilant of Server.HtmlDecode
when
>> creating a windows service?
>>
>> Thanks, 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

--
MY ASP.Net tutorials
http://www.openmymind.net/

"Sonu Kapoor" <sonukapoor@.gmail.com> wrote in message
news:18ba01c4bc87$fde97980$a601280a@.phx.gbl...
> Hi Karl,
> I get the following error when using this:
> "HttpUtility" is not a member of "web".
> Sonu
>
> >--Original Message--
> >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
> >--
> >MY ASP.Net tutorials
> >http://www.openmymind.net/
> >"Sonu Kapoor" <sonukapoor@.gmail.com> wrote in message
> >news:18a401c4bc81$7f99de90$a601280a@.phx.gbl...
> >> Hello,
> >>
> >> does anybody knows the equilant of Server.HtmlDecode
> when
> >> creating a windows service?
> >>
> >> Thanks, Sonu
> >.
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

>--Original Message--
>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
>--
>MY ASP.Net tutorials
>http://www.openmymind.net/
>
>"Sonu Kapoor" <sonukapoor@.gmail.com> wrote in message
>news:18ba01c4bc87$fde97980$a601280a@.phx.gbl...
>> Hi Karl,
>>
>> I get the following error when using this:
>>
>> "HttpUtility" is not a member of "web".
>>
>> Sonu
>>
>>
>> >--Original Message--
>> >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
>>> >--
>> >MY ASP.Net tutorials
>> >http://www.openmymind.net/
>>>> >"Sonu Kapoor" <sonukapoor@.gmail.com> wrote in message
>> >news:18a401c4bc81$7f99de90$a601280a@.phx.gbl...
>> >> Hello,
>> >>
>> >> does anybody knows the equilant of Server.HtmlDecode
>> when
>> >> creating a windows service?
>> >>
>> >> Thanks, Sonu
>>>> >.
>>
>.

Server.HtmlDecode for windows services

Hello,

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

Thanks, SonuHave you tried setting a reference to System.Web and doing:


string decoded = System.Web.HttpContext.Current.Server.HtmlDecode(encodedString);

When using this I get:

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

Sonu
uups...sorry I forgot to add the reference. It works now.

Sonu