DCSIMG
Back to Basics – How to Invoke Web Methods from a Remote Machine - Gil Fink's Blog

Gil Fink's Blog

Fink about IT

News

Microsoft MVP

My Facebook Profile My Twitter Profile My Linkedin Profile

Locations of visitors to this page

Creative Commons License

Disclaimer
The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.
© Copyright 2013 Gil Fink

Hebrew Articles

Index Pages

My OSS Projects

English Articles

Back to Basics – How to Invoke Web Methods from a Remote Machine

Back to Basics – How to Invoke Web Methods from a Remote Machine

I’ve been Back to Basics – How to Invoke Web Methods from a Remote Machine
asked today
how to enable
invocation of
WebMethods of
an asmx web service
from a remote machine
for testing.
The post holds the answer.

How to Invoke Web Methods from a Remote Machine?

Sometimes we want to test our asmx web service not from
localhost but from a remote machine. Trying to open the test form
of the web service from a remote machine will show the following
message: “The test form is only available for requests from the local
machine
”. In order to enable the invocation we need
to go the the web service’s configuration file and add to the
system.web element the following configuration:

<webServices>
    <protocols>
        <add name="HttpGet"/>
        <add name="HttpPost"/>
    </protocols>
</webServices>

The configuration will enable the protocols of Get and Post on the
service and that is it.
Pay attention – you should use this configuration only in develop or
test environments. Also, this ability is only available for simple types.
Trying it with complex types won't work.

Summary

Enabling test invocation from a remote machine is very easy. It include
simple configuration and it will work. Don’t forget to use it only in
develop or test environments.
Enjoy!

DotNetKicks Image

Comments

zaza156 said:

I want to quote your post in my blog. It can?

And you et an account on Twitter?

# December 25, 2009 11:09 AM

Gil Fink said:

zaza156 you can quote the post.

# December 26, 2009 11:32 AM