Link to home
Start Free TrialLog in
Avatar of MicheleDunham
MicheleDunham

asked on

.NET Webservice does not publish public class / properties

I have a webservice that interfaces with a SQL Database.  The webservice includes methods for interfacing with the database in the main class file in addition to several separate class files each representing a table in the database.  For instance, Customer.cs, Order.cs, OrderDetail.cs.  Each of these classes serializes fine and I can reference them without a problem in an aspx page and a Windows Form.  Recently though I added a new class Product that will not publish and I cannot come up with a reason why this is happening.  In fact any new class I create will not publish even if I copy the code from a class that does work into the file and modify the classname to match.  I'm not sure what I'm missing here.  I'm sure it must be something simple.


using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Xml.Serialization;
 
/// <summary>
/// Summary description for Product
/// </summary>
[XmlInclude(typeof(Product))]
public class Product
{
    public String ProductID;
    public Int32 CategoryID;
    public Int32 ProductTypeID;
    public String ProductTitle;
    public String ProductDesc;
    public String EnlargedImage;
    public String Thumbnail;
    public DateTime RevisionDate;
    public Char Active;
    public Int32 OrderBy;
 
    public Product()
    { }
 
    public Product(String productID, Int32 categoryID, Int32   productTypeID, String productTitle,
        String productDesc, String enlargedImage, String thumbnail, DateTime revisionDate, Char active,
        Int32 orderBy)
    {
        ProductID = productID;
        CategoryID = categoryID;
        ProductTypeID = productTypeID;
        ProductTitle = productTitle;
        ProductDesc = productDesc;
        EnlargedImage = enlargedImage;
        Thumbnail = thumbnail;
        RevisionDate = revisionDate;
        Active = active;
        OrderBy = orderBy;
    }
}

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of Solar_Flare
Solar_Flare

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
did you update the proxy object of the web service so that new changes that you do are available for consumption
Avatar of MicheleDunham
MicheleDunham

ASKER

Thanks a bunch!
I accepted this answer right after you posted it yesterday but for some reason it didn't post?
rag0017, yes I did update the proxy object.  Thanks for your comment.