Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / Web Services / September 2004

Tip: Looking for answers? Try searching our database.

Desktop client and web services - Object reference not set to an instance of an object

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Ruslan - 24 Sep 2004 08:55 GMT
Hello,

I have a desktop client application which calls web services. The
application works perfectly. But if I leave application intact about 30
minutes, and after a call a web method an exception is thrown which said:
"Object reference not set to an instance of an object".

Does anyone get this error?

Thanks,

Ruslan
Cor Ligthert - 24 Sep 2004 10:11 GMT
Ruslan,

Interesting, are you instancing the object every time new or do you have it
placed somewhere global and instanced it only at the start of the program?

Cor

"Ruslan" <ruslan_albu@hotmail.com>

> Hello,
>
[quoted text clipped - 8 lines]
>
> Ruslan
Ruslan - 24 Sep 2004 10:43 GMT
Every time the object is instanced. I have a lot of web methods, more than
100. After about 30 minutes of leaving application intact no one works. The
interesting think is that, this exception appears not at the all computers.
At some computer appear at others not. I checked the IIS, all the options
are the same.

> Ruslan,
>
[quoted text clipped - 17 lines]
> >
> > Ruslan
Nick Malik - 27 Sep 2004 15:35 GMT
Is it possible that the particular client has different proxy settings than
other clients?  If so, the proxy server may be dropping the connection after
the time expires.  I haven't run into this exactly, but my guess is that you
can reset the proxy connection by creating a new WebProxy object and use the
following code:

WebProxy proxyObject = new WebProxy("http://proxyserver:80/",true);
GlobalProxySelection.Select = proxyObject;

This should set the new proxy object to be used for all HTTPRequest calls.

I do not know for certain if this will work, so post back if it does... it
would be interesting to know.

Hope this helps,
--- Nick

> Every time the object is instanced. I have a lot of web methods, more than
> 100. After about 30 minutes of leaving application intact no one works. The
[quoted text clipped - 25 lines]
> > >
> > > Ruslan

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.