On enabling Viewstate encodin I am getting "Invalid charect"

Forum for users of ANTS web server load testing tool

Moderator: Brian Donahue

On enabling Viewstate encodin I am getting "Invalid charect"

Postby Ajay » Mon Jun 05, 2006 5:04 pm

In one of the posts in the forum I read inorder to resolve Viewstate issue we have to encode it before sending to the server. But on enabling the viewstate encoding i am getting the following error:

System.FormatException: Invalid character in a Base-64 string.
at System.Convert.FromBase64String(String s)
at System.Web.UI.LosFormatter.Deserialize(String input)
at System.Web.UI.Page.LoadPageStateFromPersistenceMedium()

Base Exception: System.FormatException: Invalid character in a Base-64 string.
at System.Convert.FromBase64String(String s)
at System.Web.UI.LosFormatter.Deserialize(String input)
at System.Web.UI.Page.LoadPageStateFromPersistenceMedium()

Any help or suggestions are appriciated.

Thanks & Regards
Ajay
Ajay
 
Posts: 5
Joined: Thu May 11, 2006 4:31 pm
Location: Albany

Postby Brian Donahue » Thu Jun 08, 2006 7:23 pm

What do you mean by viewstate encoding?

I remember one case where the user's webserver used a home-made viewstate because the viewstate was quite large and they wanted to compress it. This resulted in a hidden field in the web page called __COMPRESSEDVIEWSTATE, which of course, ANTS Load can't handle automatically. If this is the case, then part of you test script would need to include a special function to parse the viewstate out of the WebClient.HttpResponse.Content into a variable and post it back to the server. I think you may be in a similar situation?
Brian Donahue
 
Posts: 6670
Joined: Mon Aug 23, 2004 10:48 am

Issue Resolved

Postby Ajay » Thu Jun 08, 2006 7:34 pm

Hi Brian,

Welcome back from vacation. ...

Well I was receiving the mentioned error, when I am trying to encode the webclient.viewstate. Instead what I am doing is capturing the Viewstate from the response body and I am encoding it while adding to Postdata. It is working fine.

Thanks & Regards
Ajay
Ajay
 
Posts: 5
Joined: Thu May 11, 2006 4:31 pm
Location: Albany

Postby Brian Donahue » Fri Jun 09, 2006 6:04 pm

Hi Ajay,

If that's working for you, all the best! Normally this wouldn't be necessary unless there is something 'special' about the viewstate data like I mentioned in my previous reply.
Brian Donahue
 
Posts: 6670
Joined: Mon Aug 23, 2004 10:48 am


Return to ANTS Load

Who is online

Users browsing this forum: No registered users and 1 guest