Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6766353
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T14:49:14+00:00 2026-05-26T14:49:14+00:00

I am using SignalR in an ASP.Net Web Application project and am having issues.

  • 0

I am using SignalR in an ASP.Net Web Application project and am having issues. My goal is to make any changes in the administrative side of the site cause some GridViews to refresh. I was planning on doing this by sending the signal for some javascript to be run, thereby refreshing the update panels containing the GridViews.

The issue right now is that I cannot get any of the code my hub is trying to call to execute in the client. I am receiving the following error in FireBug from the jquery.SignalR.js file, but I’m not sure how to proceed to fix it:

Firefox can't establish a connection to the server at ws://localhost:40068/signalr?data=[]&transport=webSockets&clientId=92e4f7b9-0118-4fd9-bb55-5f22338d6162.

(function(n,t){"use strict";if(typeof ...on=n.signalR=i})(window.jQuery,window)

After it throws this error it still looks like it is setting up the connection, but none of the javascript being sent through the hub is executed

I have set up the following hub in my site:

namespace testProject
{
    public class statusChanges : Hub
    {
        public void ServerChange()
        {
            Clients.serverChange();

        }
    }
}

I have the following code in my button click event in the admin section. Debugging shows that this code is being run by the server:

var clients = Hub.GetClients<statusChanges>();
clients.serverChange();

Finally I have this code in my page trying to just launch an alert when it receieves the signal to confirm it is working.

<script type="text/javascript">
    $(function () {
        var statusChange = $.connection.statusChanges;
        statusChange.serverChange = function () {
            alert(8);
        };
        $.connection.hub.start();
    });
</script>

Does any one have any ideas why this would not run or what the FireBug error means?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T14:49:14+00:00Added an answer on May 26, 2026 at 2:49 pm

    The error in firebug is expected. It’s the websocket connection failing, don’t worry about it as SignalR will fallback to longpolling. You have a method on the server side with the same name as a client side event. That doesn’t work.

    You want something like this:

    public Administration : Hub {
    }
    

    Event handler:

    var clients = Hub.GetClients<Administration>();
    clients.serverChange();
    

    Javascript:

    <script type="text/javascript">
        $(function () {
            var administration= $.connection.administration;
            administration.serverChange = function () {
                alert(8);
            };
            $.connection.hub.start();
        });
    </script>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Using ASP.NET MVC there are situations (such as form submission) that may require a
Using VS2008, C#, .Net 2 and Winforms how can I make a regular Button
I'm connecting to an ASP.NET webservice using the HTTPConnection class in Blackberry, but when
I am building an ASP.NET application. The application uses forms authentication. I am not
I’m developing a Ray Tracer in C++ using SDL and Pthread. I’m having issues
I've inherited a web application which heavily uses Anthem.net. There is one operation which
I have an asp.net vb project that needs to parse some raw XML that
I'm using SignalR to process clicks from the client on my MVC3 application. Every
I'm attempting to use SignalR hubs in an application, but am having no luck
My application is developped in C++ using Qt and is using signals and slots.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.