Connection Timeout Expired. The timeout period elapsed while attempting to consume the pre-login handshake acknowledgment

I have an ASP.Net website that connects to SQL server always-on failover cluster instance.

But I have a strange behavior when I configured the Connection String inside Web.Config as SQL Authentication, the connection has been connected successfully.

Server=load balancer IP;Database=Database Name;User Id=User; Password=Password; 

Bu when I tried to configure the Connection String as Windows Authentication.

Server=load balancer IP;Database=Database Name;Integrated Security =true;

I got the following error.

Connection Timeout Expired. The timeout period elapsed while attempting to consume the pre-login handshake acknowledgement.
This could be because the pre-login handshake failed or the server was unable to respond back in time.

connection-timeout-expired.png

I made sure that the application pool service account has elevated privilege with SQL Server as public server role and user mapping database. but unfortunately, the issue still persist.

Cause: Continue reading “Connection Timeout Expired. The timeout period elapsed while attempting to consume the pre-login handshake acknowledgment”

Advertisements

No http handler was found for request type ‘GET’ in SharePoint Visual WebPart

I tried to use Asp.Net Chart control within SharePoint Visual WebPart, After I deployed the SharePoint Solution, I tried to add Chart visual webpart to SharePoint page, I got the following server error.

No http handler was found for request type 'GET'

Chart Configuration

Cause: Continue reading “No http handler was found for request type ‘GET’ in SharePoint Visual WebPart”

In remote mode, the Report Viewer control requires session state be enabled or Report Server connection information specified in the config file.

When I tried to use a Report Viewer Control within a SharePoint Visual Web Part, I got the following error !

In remote mode, the Report Viewer control requires session state be enabled
 or Report Server connection information specified in the config file.

ReportViwer

Cause: Continue reading “In remote mode, the Report Viewer control requires session state be enabled or Report Server connection information specified in the config file.”

WebForms UnobtrusiveValidation Mode requires a ScriptResourceMapping for jQuery

In a specific situation (like using required validator) you may get the below server error:

Error : WebForms UnobtrusiveValidationMode requires a ScriptResourceMapping for ‘jquery’. Please add a ScriptResourceMapping named jquery (case-sensitive).

scriptresourcemappingSolution:  Continue reading “WebForms UnobtrusiveValidation Mode requires a ScriptResourceMapping for jQuery”

The base class includes the field ‘XXX’, but its type is not compatible with the type of control Microsoft.Reporting .WebForms.ReportViewer

When I tried to upgrade asp.net solution that had been developed via Visual Studio 2008 to a SharePoint solution, I got the following error

The base class includes the field 'rv_emp', but its type 
(Microsoft.Reporting.WebForms.ReportViewer) is not compatible with 
the type of control (Microsoft.Reporting.WebForms.ReportViewer)

Specifically when I tried to use the report viewer control .

1

Cause: Continue reading “The base class includes the field ‘XXX’, but its type is not compatible with the type of control Microsoft.Reporting .WebForms.ReportViewer”

Missing design view after editing Front-Code of Web User Control in ASP.NET

I have a web user control within ASP.NET web application, and When I am trying to edit Front-code, I got unexpected behavior! where the ASP.NET controls have been disappeared and the design view became a blank as shown below !

Modify UserControl

Cause :  Continue reading “Missing design view after editing Front-Code of Web User Control in ASP.NET”

To display the webpage again, the web browser needs to resend the information

During developing ASP.Net solution,I got this warring message from Internet Explorer when the Page tried to do PostBack .

Errorrendering

Firstly I tried to change the form method in HTML file from POST to GET .

<form id="form1" runat="server" method="get">

Now it’s working properly,but I can’t send QueryString value in URL.

I checked the code again and I discovered that I was using a JavaScript code in “OnClosed” FancyBox event as shown below:

'onClosed': function() { window.location.reload(); }

I changed window.location.reload() to window.location=’URL’


Note : If you use a QueryString in URL and you need to don’t lose the current value after reload so you should use

window.location='../Default.aspx?Lang=<%=Request.QueryString["Lang"]%>''
Where Lang is the QueryString variable

Enjoy 🙂