GSSP-.NET · Question #441
(Topic 4) Allen works as a Software Developer for Mansoft Inc. He develops a Web application using Visual Studio .NET. He adds a Web reference to an XML Web service named MyWebService in the…
The correct answer is A. System.Web.Services.Protocols.SoapException. See the full explanation below for the reasoning.
Question
- (Topic 4)
Allen works as a Software Developer for Mansoft Inc. He develops a Web application using Visual Studio .NET. He adds a Web reference to an XML Web service named MyWebService in the application. MyWebService includes a method named MyMethod, which takes user identification number as a parameter and returns a DataSet object containing user information. The System.ArgumentException is thrown if the user identification number does not lie between 1 and 500. Allen writes a try and catch block to capture the exception thrown by the Web service. Which of the following exceptions will the try and catch block catch if a user calls MyMethod passing 501 as a parameter?
Options
- ASystem.Web.Services.Protocols.SoapException
- BSystem.Web.Services.Protocols.SoapHeaderException
- CSystem.ApplicationException
- DSystem.ArgumentNullException
How the community answered
(48 responses)- A75% (36)
- B15% (7)
- C4% (2)
- D6% (3)
Community Discussion
No community discussion yet for this question.