[dba-VB] How to Consume a Web Service (Request for Help, not urgent)

Shamil Salakhetdinov shamil at smsconsulting.spb.ru
Mon Aug 31 17:28:49 CDT 2009


Hi All,

I have finally got the following runtime error messages:

<<<
Unable to connect to the remote server
Could not connect to http://localhost:59057/Service1.svc. 
TCP error code 10061:
No connection could be made because the target machine actively refused it 
127.0.0.1:59057.
>>>

And I'm not working with any remote servers here - this is just one system
I'm testing on/working with.

I have tried to suppress firewall completely, I have tried to open 59057
port - no luck...

The issue (they tell somewhere) could be also that this machine has several
NICs - usual cable and wireless etc.

Googling/Binging didn't give any clues to solve the issue effectively.

I'm leaving it for now for the "better times"...

I have "Pro WCF, Practical Microsoft SOA Implementation" book - I should
probably read it very carefully through to understand every bit in WCF
configuration and functioning... (BTW, I didn't need to read any books and
almost no any docs to implement several SOAP (.asmx) ASP.NET Web Services,
which work successfully in production for several years, and they work well
on this my system I'm currently "struggling with very basic WCF Web Service"
- it could be a bad day here also today...)

Still I think that modern MS technologies are great and easy to use :)

Thank you for your help.

--
Shamil


-----Original Message-----
From: dba-vb-bounces at databaseadvisors.com
[mailto:dba-vb-bounces at databaseadvisors.com] On Behalf Of Shamil
Salakhetdinov
Sent: Monday, August 31, 2009 9:29 PM
To: 'Discussion concerning Visual Basic and related programming issues.'
Subject: Re: [dba-VB] How to Consume a Web Service (Request for Help, not
urgent)

Hi All,

I have got a helping hand from Mike, Gustav and Doug who happened to be
"Lucky Guys" (thank you guys!) - they have referred below sample working
well "out of the box".

This sample solution (in Mike's interpretation) is posted here:

http://northwind.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=26600#D
ownloadId=81391  (~65KB)

It can be used as a test to see if your system is "WCF Web Services
Development Ready".

It has now WCF web service reference set OK (as this reference setting
happened on Mike's VS2008) but when I run it I'm getting runtime error:

"The communication object, System.ServiceModel.Channels.ServiceChannel,
cannot be used for communication because it is in the Faulted state."

I'm currently "digging further" trying to make this sample working on my
system - here is some information I'm looking through:

How to make sure you don't get WCF Faulted State Exception?
http://stackoverflow.com/questions/530731/how-to-make-sure-you-dont-get-wcf-
faulted-state-exception 

Avoiding Problems with the Using Statement
http://msdn.microsoft.com/en-us/library/aa355056.aspx 

I will inform you on my further progress (if any).

Thank you for your help.

--
Shamil

P.S. I haven't been "fighting" with this issue all the working day through,
I was already in swimming pool with my kid etc. - yet this issue is one of
the representative cases what make software development so "heavy" sometimes
- the best/quickest solutions for such issues seems to be clean reinstalls
of the systems, and having just latest release versions of MS software on
that systems: still have to find time/resources to prepare something like
that - this current case could be the "last drop"...


-----Original Message-----
From: dba-vb-bounces at databaseadvisors.com
[mailto:dba-vb-bounces at databaseadvisors.com] On Behalf Of Shamil
Salakhetdinov
Sent: Monday, August 31, 2009 1:57 PM
To: 'Discussion concerning Visual Basic and related programming issues.'
Subject: [dba-VB] How to Consume a Web Service (Request for Help, not
urgent)

Hi All,

 

I'd be very grateful if anybody could go through the following
sample/workthrough using VS2008 SP1

 

"How to Consume a Web Service"

http://johnwsaundersiii.spaces.live.com/?_c11_BlogPart_BlogPart=blogview&_c=
BlogPart&partqs=amonth%3d5%26ayear%3d2009

(watch line wraps)

 

and publish for download/send me privately the sources you'll get. I can't
get this sample working on my system (something is still wrong with my
system setup), and I wanted to compare your sources with the ones I'm
getting here to find out how to solve this "nightmarish" issue.

 

If all will work well it should take several minutes to make the sample
working on your system assuming you have VS2008 SP1 and Windows SDK
installed.

 

Please do not try to look for workarounds if the above sample will not work
out of the box as described - looking for such workaround can take hours and
hours  (and solution depends on your system (current) context/previous
setups I believe) - you'll risk to lose your working day.

 

Solution/workaround should be simple, effective and generic - I still can't
find it nor by myself nor by intensive Googling/Binging.

 

Thank you.

 

--

Shamil

 

 


 

__________ Information from ESET NOD32 Antivirus, version of virus signature
database 4385 (20090831) __________

The message was checked by ESET NOD32 Antivirus.

http://www.esetnod32.ru
 




More information about the dba-VB mailing list