Click here to Skip to main content
16,017,788 members
Please Sign up or sign in to vote.
5.00/5 (1 vote)
See more:
I have a server code as shown below and client code further below. In the Client code I am trying to start a HubConnection but I keep getting an System.AggregateException when I include .Wait() on
C#
connection.Start()


C#
namespace SignalRServer
{
    public class Program
    {
        static void Main(string[] args)
        {
            string url = "http://localhost:8080";

            using (WebApp.Start<StartUp>(url))
            {
                Console.WriteLine("Server running on {0}", url);
                Console.ReadLine();
            } 
        }
    }
    class StartUp
    {
        public void Configuration(IAppBuilder app)
        {
            app.MapSignalR();
        }
    }

}


My Client Code
C#
var connection = new HubConnection("http://localhost:8080");
            var my_hub = connection.CreateHubProxy("ChatHub");

            connection.Start().Wait();
Posted

1 solution

I have a same problem. Have you any solution?
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900