Invalid length for a Base-64 char array or string. c#

0

I've been encountering this error message for a while. I tried to replicate the issue and was successful on replicating it by clicking on a wizard button while the loading is still on going. I tried to disable the buttons and other elements by using a script that will disable this elements during pageload and will enable them after but it still not works. I supposed this issue is because of postback but the fix is not working. And I am not sure if that is the only way to replicate the issue but so far thats the only way i found it.

Invalid length for a Base-64 char array or string.

System.FormatException Invalid length for a Base-64 char array or string.
System.Web.HttpException (0x80004005): The client disconnected.
---> System.Web.UI.ViewStateException: Invalid viewstate.
User-Agent: Mozilla/5.0 (X11; CrOS x86_64 11316.123.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.97 Safari/537.36

ViewState: vwfnk+yfSQJi22s3A+upcornE4ngrVGbj7MGaXOxHO1mBsxv/1m0vyMIlLBc3FhiXWqXouB/DlFlt/E9QOF26fNkngtxeJ53g2gSdz4BhaDcFamwFAhwqu32CDkFUW84/+cpdJpvgEz7gZ3EIEmX4xo8gZLXMDcNV4g1cd9ELHmlyUZAw7W4denfEcZmLkGoA1FyGuGb9O0uJILVddcvB4ZZDmciIxzyLr8nczysqqOi9Ml
---> System.FormatException: Invalid length for a Base-64 char array or string.

at System.Convert.FromBase64_Decode(Char* startInputPtr, Int32 inputLength, Byte* startDestPtr, Int32 destLength)
at System.Convert.FromBase64CharPtr(Char* inputPtr, Int32 inputLength)
at System.Convert.FromBase64String(String s) at System.Web.UI.ObjectStateFormatter.Deserialize(String inputString, Purpose purpose)
System.Web.UI.Util.DeserializeWithAssert(IStateFormatter2 formatter, String serializedState, Purpose purpose)
at System.Web.UI.HiddenFieldPageStatePersister.Load()
--- End of inner exception stack trace ---

c#
asp.net
webforms
viewstate
asked on Stack Overflow Feb 19, 2019 by Kevin Jacob • edited Feb 19, 2019 by Kevin Jacob

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0