Wrox Programmer Forums
Go Back   Wrox Programmer Forums > .NET > Other .NET > General .NET
|
General .NET For general discussion of MICROSOFT .NET topics that don't fall within any of the other .NET forum subcategories or .NET language forums.  If your question is specific to a language (C# or Visual Basic) or type of application (Windows Forms or ASP.Net) try an applicable forum category. ** PLEASE BE SPECIFIC WITH YOUR QUESTION ** When posting here, provide details regarding the Microsoft .NET language you are using and/or what type of application (Windows/Web Forms, etc) you are working in, if applicable to the question. This will help others answer the question without having to ask.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the General .NET section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old May 18th, 2005, 06:06 PM
Friend of Wrox
 
Join Date: Sep 2003
Posts: 101
Thanks: 0
Thanked 0 Times in 0 Posts
Default calling webservice in console app error

I created webservice with one webmothod like below

namespace X.Y.Z
{

        [WebMethod]
        public bool doCreate(Myobj amyobj)
        {
            return(amyobj.Create());
        }


}
here Myobj is a class existing in one of my class Library

 when i call this from ASP.NET client (means Webform1.aspx) its working fine.


but when i try to call the Webservice from my console aplication i am getting error

I created web reference in my console application.and calling webservice like below

here my class also belongs to namespace X.Y.Z

localhost.DBWebService aDBWebService=new localhost.DBWebService ();

'here localhost is name of web reference and DBWebService is name of my webservice.

return(aDBWebService.doCreate(amyobj));

above line i am getting problem
its expecting the parameter X.Y.Z.localhost.Myobj INSTEADOF X.Y.Z.Myobj for my doCreate method.

pl advice me where is the problem.


 
Old October 25th, 2006, 09:38 PM
Registered User
 
Join Date: Oct 2006
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I know this is kind of late, but were you ever able to resolve this problem ? I am also calling a WebService from a .Net Console App...

Thanks !






Similar Threads
Thread Thread Starter Forum Replies Last Post
C++ console app barrytn Visual C++ 2005 2 July 11th, 2008 02:11 AM
Error calling a method in the webservice madhusrp .NET Web Services 1 April 12th, 2007 08:54 AM
Schedule a console app hamilton General .NET 1 January 5th, 2007 10:50 AM
is making console app using C# a waste rahulmballal BOOK: Professional C#, 2nd and 3rd Editions 0 January 25th, 2005 11:13 AM
invisible console app asmotritsky Visual C++ 1 November 25th, 2004 03:27 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.