Welcome Guest Search | Active Topics | Sign In | Register

bug in callback with turkish language Options
Jhon s
Posted: Wednesday, June 20, 2007 7:11:51 AM
Rank: Advanced Member
Groups: Member

Joined: 5/31/2007
Posts: 36
I get an exception (“The state information is invalid for this page and might be corrupted”)
after clicking the button the second time.
I’m using the Turkish culture info


<%@ page language="VB" autoeventwireup="false" codefile="Default.aspx.vb" inherits="_Default" %>

<%@ register assembly="EO.Web" namespace="EO.Web" tagprefix="eo" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>Untitled Page</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<eo:callbackpanel id="CallbackPanel1" runat="server" height="150px" width="200px" triggers="{ControlID:Button1;Parameter:}">
<asp:button id="Button1" runat="server" text="Button" /><asp:label id="Label1" runat="server"
text="0"></asp:label>
</eo:callbackpanel>
</div>
</form>
</body>
</html>



Partial Class _Default
Inherits System.Web.UI.Page

Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click
Label1.Text = Label1.Text + 1
End Sub

Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
System.Threading.Thread.CurrentThread.CurrentCulture = New System.Globalization.CultureInfo("tr-TR")
System.Threading.Thread.CurrentThread.CurrentUICulture = New System.Globalization.CultureInfo("tr-TR")
End Sub
End Class



Server Error in '/WebSite1' Application.
________________________________________
The state information is invalid for this page and might be corrupted.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Web.HttpException: The state information is invalid for this page and might be corrupted.

Source Error:
The source code that generated this unhandled exception can only be shown when compiled in debug mode. To enable this, please follow one of the below steps, then request the URL:

1. Add a "Debug=true" directive at the top of the file that generated the error. Example:

<%@ Page Language="C#" Debug="true" %>

or:

2) Add the following section to the configuration file of your application:

<configuration>
<system.web>
<compilation debug="true"/>
</system.web>
</configuration>

Note that this second technique will cause all files within a given application to be compiled in debug mode. The first technique will cause only that particular file to be compiled in debug mode.

Important: Running applications in debug mode does incur a memory/performance overhead. You should make sure that an application has debugging disabled before deploying into production scenario.

Stack Trace:

[ViewStateException: Invalid viewstate.
Client IP: 127.0.0.1
Port:
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.2; SV1; .NET CLR 1.1.4322; .NET CLR 2.0.50727; FDM)
ViewState: /wEWAgKJiPuZCQKM54rGBveqRo6vWUA2N8CZcDpUu2yIRg/6
Referer: http://localhost:3129/WebSite1/Default.aspx
Path: /WebSite1/Default.aspx]

[HttpException (0x80004005): The state information is invalid for this page and might be corrupted.]
System.Web.UI.ViewStateException.ThrowError(Exception inner, String persistedState, String errorPageMessage, Boolean macValidationError) +171
System.Web.UI.ViewStateException.ThrowViewStateError(Exception inner, String persistedState) +37
System.Web.UI.ClientScriptManager.EnsureEventValidationFieldLoaded() +371
System.Web.UI.ClientScriptManager.ValidateEvent(String uniqueId, String argument) +203
System.Web.UI.Control.ValidateEvent(String uniqueID, String eventArgument) +83
System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +52
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +31
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +32
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +244
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5911
System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +188
System.Web.UI.Page.ProcessRequest() +112
System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context) +37
System.Web.UI.Page.ProcessRequest(HttpContext context) +135
ASP.default_aspx.ProcessRequest(HttpContext context) +29
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +401
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +117
Code: Visual Basic.NET
eo_support
Posted: Wednesday, June 20, 2007 7:17:04 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,193
Hi Ilan,

Thanks for posting your question here. You need to set the page's encoding to utf-8. You can do this in your web.config:

Code: HTML/ASPX
<globalization
    requestEncoding="UTF-8"
    responseEncoding="UTF-8">
</globalization>


Note the encoding and your culture are two different things. You can still set your culture to your local culture.

Thanks


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.