Problems passing an array to a web service

I right click on the Notification object and click on Show Definition

public class Notification

{ public Notification();

public string Message { get; set; } public Provider[] Recipients { get; set; } public string Sender { get; set; } public string Subject { get; set; } 


I need to add a Provider object to that array there but it's not working.

I new up the object: Notification myNotification = new Notification();

At run time, the size of the array for the Recipients has been set to null. I can't seem to find a way to tell the #$&^ that it should open up it's stupid mouth and let me add an instance of Provider to it.

How might I go about this?


by SequesterMe via /r/csharp

One Reply to “Problems passing an array to a web service”

  1. Provider p = new Provider();
    List pList = new List();

    //when you call the method to send to webservice:
    Webservice a = new webservice(); //create web service object

Leave a Reply