I have created a ‘wizard’ and the user has to step thru 5 screens to complete
On step 4 I have a page from which the user can select one of 9 values from a dropdown control.
I have bound the change() event of the dropdown in jquery to an ajax post which posts to a controller action that returns a partial view depending on the users selection
Before moving on to the 5th and final step in the wizard the data in step 4 gets verified by a 3rd party service. If this service is not available then the user gets presented with a screen where one of the options is to ‘Try Again’. This is where my problem is
I need to go back to step 4 and have the data loaded with what the user populated in step 4 but since the controls were rendered by the partialview from an ajax call I dont know how I can present the view and have it populated without the user starting over and selecting one of the options and then repopulating the partial view
EDIT: I have the data in the model. This is persisted in TEMPDATA This is not the problem The problem is to re-render the view and repopulate
Found a way – I’ve placed a flag in the control to detect it is a ‘TryAgain’ attempt and placed logic in the view which detects this and ‘rebuilds’ the view