By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
449,017 Members | 997 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 449,017 IT Pros & Developers. It's quick & easy.

TESTING WEB SERVICE IN BROWSER

P: n/a
Hei,
I have a web service with web methods that take nullable DateTime parameters
(i.e., DateTime?)
When i open the service in IE7, I get the message that those methods cannot
be viewed ("not primitive types");
the other web methods can be invoked without problems.
Any suggestions on how I can change IE7 settings or something else?
Kind regards,
Tom Pederen
Oct 8 '08 #1
Share this Question
Share on Google+
3 Replies


P: n/a
"TompIfe" <tp******@community.nospamwrote in message
news:eT**************@TK2MSFTNGP05.phx.gbl...
Hei,
I have a web service with web methods that take nullable DateTime
parameters (i.e., DateTime?)
When i open the service in IE7, I get the message that those methods
cannot be viewed ("not primitive types");
the other web methods can be invoked without problems.
Any suggestions on how I can change IE7 settings or something else?
This has nothing to do with IE. The web page created from your service does
not know how to deal with anything other than primitive types.

You should create a client to test your service in any case. Such a
client-based test can be created in a unit test, using NUnit or the unit
test tool in Visual Studio Team System Developer Edition. That allows the
test to be run automatically, with a clear pass/fail report.

--
John Saunders | MVP - Connected System Developer

Oct 8 '08 #2

P: n/a
Hi Tom,

As for the WebService Test page issue, it is due to the type system
supported by the test page. Generally, for ASMX webservice, it will try to
generate a web page for user to test the webmethods. However, those page
use textbox to accept parameters, therefore, it will only be able to afford
simple types(such as the primitive types--- int, string, bool....). Those
complex type such as DateTime or custom class is not supported by this test
webservice page.

As John mentioned, if you want to fully test a webservice, you can simply
create a console application and "Add WebReference" agains the service to
test it. In addition, the advantage of testing via "generated proxy" (over
the web page test interface) is that webservice proxy is using SOAP
protocol to invoke the webservice while the test page use simply http get
verb which cannot fully covers all the characters of SOAP based XML
webservice.

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead
Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
ms****@microsoft.com.

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/en-us/subs...#notifications.

==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
From: "TompIfe" <tp******@community.nospam>
Subject: TESTING WEB SERVICE IN BROWSER
Date: Wed, 8 Oct 2008 13:07:02 +0200
Hei,
I have a web service with web methods that take nullable DateTime
parameters
(i.e., DateTime?)
When i open the service in IE7, I get the message that those methods cannot
be viewed ("not primitive types");
the other web methods can be invoked without problems.
Any suggestions on how I can change IE7 settings or something else?
Kind regards,
Tom Pederen

Oct 9 '08 #3

P: n/a
Hi,
I have created a client that consumes the web service and it works fine.
I am not familiar with unit tests, but I will look into it.
Thank you for your assistance.
Tom Pedersen
"John Saunders" <no@dont.do.that.comwrote in message
news:eF*************@TK2MSFTNGP06.phx.gbl...
"TompIfe" <tp******@community.nospamwrote in message
news:eT**************@TK2MSFTNGP05.phx.gbl...
>Hei,
I have a web service with web methods that take nullable DateTime
parameters (i.e., DateTime?)
When i open the service in IE7, I get the message that those methods
cannot be viewed ("not primitive types");
the other web methods can be invoked without problems.
Any suggestions on how I can change IE7 settings or something else?

This has nothing to do with IE. The web page created from your service
does not know how to deal with anything other than primitive types.

You should create a client to test your service in any case. Such a
client-based test can be created in a unit test, using NUnit or the unit
test tool in Visual Studio Team System Developer Edition. That allows the
test to be run automatically, with a clear pass/fail report.

--
John Saunders | MVP - Connected System Developer

Oct 9 '08 #4

This discussion thread is closed

Replies have been disabled for this discussion.