Cannot send data if the connection is not in the 'Connected' State

Hi All,

I am using licensed UD 2.5.3 on IIS with windows authentication enabled, running on port 80.
I have a grid which displays data, from SQL DB, I added a button to the grid which performs some calculations and using Show-UDModal display it. However, as soon as I click on the button the following message appears: Cannot send data if the connection is not in the ‘Connected’ State.

If I am running the same on localhost, it work as expected.

Please help to understand where is the problem and how to fix it.

Thank you.

BTW, same happening, when I am trying to present values not from a query, using Adam’s example:

Another strange thing, when some time passed ~ 5 min(appears like reaching websocket timeout), the buttons start to work.

Here is a screenshot from developer tools of errors that appears:

Hi @shykhovtsov are you able to post some code behind this? I too am using 2.5.3 and SQL DB and have no issues on displaying a model for example via a button I build into the grid. Sounds like you are loosing connection to your DB. Bit hard to troubleshoot without seeing your code…So if possible please upload, I do have some examples of how I am doing this on gihub under the same alias I use here psdevuk

Do you have web sockets enabled in IIS?

Hi @psDevUK
As i mentioned above, it is not related to SQL, here is example of code without SQL query which is not working when I am accessing the dashboard from remote.
Here is the page code:

New-UDPage -Name 'Test' -Content {
New-UDGrid -Title "Processes" -Headers @("Process Name", "Id", "View Modules") -Properties @("Name", "Id", "ViewModules") -Endpoint {
    Get-Process | ForEach-Object {
            Name        = $_.Name
            Id          = $_.Id
            ViewModules = New-UDButton -Text "View Modules" -OnClick (New-UDEndpoint -Endpoint { 
                    Show-UDModal -Content {
                        New-UDTable -Title "Modules" -Headers @("Name", "Path") -Content {
                            $ArgumentList[0] | Out-UDTableData -Property @("ModuleName", "FileName")
                } -ArgumentList $_.Modules)
    } | Out-UDGridData


Please share your thoughts, why it can happen.
Thank you!

Web-socket feature is installed.
Here is the module status:

And here is the configuration

Please let me know if I am missing something.

On my iPhone atm as my kids want me to take them out…anyways so just asking before I’m assuming but I run everything through my windows 10 pc through iis. Is this the same for you? Sounds similar. Can you ping iis machine from remote machine ok? Is it just this dashboard or any dashboard you having issues with? I had to run some firewall commands through good old cmd for my dashboard to work. Peace

I am using windows 10, target IIS server is windows 2016.
All the ports are open between client and server.

Found something interesting, tried to execute it using edge and it is working - but, in console there are other errors.
Before tested it on Chrome, Version 76.0.3809.132 (Official Build) (64-bit)

Hi All,

I found the issue - it was combination of chrome and “Set Character Encoding” extension, as soon as I disabled this extension everything started to work.

Very sorry for all the noise and thank you for prompt support!