Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Services > web method return type

Reply
Thread Tools

web method return type

 
 
niraj
Guest
Posts: n/a
 
      04-06-2004
Hi;

Can WebMethod return Interface type?
I am getting System.InvalidOperationException
Followin is code...

public interface IDBData
{

/// <summary>
/// PrimaryKey value
/// </summary>
long ID
{
get;
set;
}
}

//In WebService class
[WebMethod(Description="Get data from DB, given primaryKey & dataType")]
public IDBData Retrieve(long primaryKey, DBTypes dataType)
{
return m_Server.Retrieve( primaryKey, dataType );
}

Thanks for your reply

Niraj



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Why is return type in getfullspec().annotations named as "return"? andrew cooke Python 1 04-03-2011 01:02 AM
Carriage Return added during return of large string from class method Xeno Campanoli Ruby 0 02-13-2006 08:39 PM
what value does lack of return or empty "return;" return Greenhorn C Programming 15 03-06-2005 08:19 PM
Re: How do I access another type's method from one type's method Howard C++ 2 07-04-2003 12:08 PM
Re: How do I access another type's method from one type's method Rolf Magnus C++ 1 07-04-2003 02:38 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57