Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using Microsoft.AspNet.SignalR;
- using Microsoft.AspNet.SignalR.Hubs;
- public class ChatHub : Hub
- {
- [HubMethodName("sendMessages")]
- public static void SendMessages()
- {
- IHubContext context = GlobalHost.ConnectionManager.GetHubContext<ChatHub>();
- context.Clients.All.updateMessages();
- }
- }
Add Comment
Please, Sign In to add comment