Page 1 of 1

When rendering all pages in one HTML file, drop down lists and labels are not being cleared.

Posted: Wed Jun 11, 2014 8:59 pm
by Mark6921260

I have rendered all pages into one HTML file.
When I first visit a page, select some options, then navigate away from that page, and then return to the same page to do another selection- the selections I chose previously as well as any messages are still there.
Image

How do I make it where when the screen is returned to it displays like the first time it is shown. Example below:
Image


When rendering all pages in one HTML file, drop down lists and labels are not being cleared.

Posted: Wed Jun 11, 2014 11:02 pm
by Yurii Orishchuk

Hi Mark.

You need to reset selected values in default state on "page show" event.

Please follow these steps:

1 Open page in Design mode.

2 Open "events" bottom panel.

3 Select in component select your page and add "page show" JS event handler with code below:

precode

//Here is you need replace "mobileselectmenu_16" with your select component name.
//Also you need to change "defaultSelectValue" with your default value.
Appery("mobileselectmenu_16").val("defaultSelectValue");
Appery("mobileselectmenu_16").selectmenu("refresh", true);

/code/pre

See details on screen shot: http://prntscr.com/3rxrcw/direct

That's all.

Regards.


When rendering all pages in one HTML file, drop down lists and labels are not being cleared.

Posted: Thu Jun 12, 2014 1:37 am
by Mark6921260

This worked perfectly.
I used the same process to refresh the image that is returned based on the previous screens selection.
Thank you Yurii.