1

I have a WizardStep Control from which i need one information: The total amount from a webshop cart. As i searched and asked this forum my conclusion was that this couldn't be done by passing a hiddenfield or a hidden textbox value to the next page from a WizardStep Complete step. So i tried to put this information into a session then directed to a new page where i make a form textbox whos value would be the session value.

But i get the Validation of viewstate MAC failed error. I have tried to delay the submit call by 3 seconds, but that itn't help and i dont run the site at a webfarm.

The reason that i need the textbox is that my payment gateway requires that i pass the total amount through form values.

Here is the page that my wizard control directs to. Its just a test page atm. Right now i just need to transfer a value from the textbox to the next page without the viewstate error:

<script type="text/javascript" language="javascript">
    window.onload = function() {
        setTimeout('submitForm()', 3000);

    }

    function submitForm() {
        document.forms[0].submit();
    }
</script>

<div>

Poku
  • 3,138
  • 10
  • 46
  • 64

1 Answers1

2

Usually, the viewstate error occurs because a page is refreshed before it is finished loading as in this question. Given that this is a simple page to just redirect the data, I would ensure you are using an HTML input element, and not an ASP TextBox control (or any other ASP controls), which should completely remove the viewstate from the page.

Community
  • 1
  • 1
Jason Berkan
  • 8,734
  • 7
  • 29
  • 39