Diese Seite mit anderen teilen ...

Informationen zum Thema:
WinDev Forum
Beiträge im Thema:
Erster Beitrag:
vor 2 Jahren
Letzter Beitrag:
vor 2 Jahren
Beteiligte Autoren:
JP, Fabrice Harari

[WB21] - Table Control Click to Load Page

Startbeitrag von JP am 14.06.2016 07:00

Hi All

Classic Site

I have an Ajax type Table control on a page with some rows the user can select. But there seems no way to load a page when a row is selected.

1) Table is Ajax

a) Trying to use PageDisplay() in Table control server click code cause error "PageDisplay not allowed in WebDev Ajax"

b) Trying to use PageDisplay() in Table control browser click code causes error "Page must be static, not dynamic"

2) Table is Browser

Similar issues that you can't get a dynamic page to load from a browser based control.

The workaround is I put a button on the page as well. The user then selects a row and then he must click the button. The button retrieves the row selected and loads a dynamic page on the server. But what a kludge! Why can't I just load a page when the user clicks a row kn the table? Is it possible and I miss something or is this the way it is ?



Hi JP,

this is one of the trade off for the ajax mode...

So you have HALF the solution...

You already have your button, and now, in the browser area of the line selection, do a executeprocess of the button clic. THat will execute first the browser code of the button, then its SERVER code. and as this server code is NOT in ajax, you can do a pagedisplay.

Of course, the button can be hidden

Best regards

von Fabrice Harari - am 14.06.2016 13:13

LOL! That is 100% exactly what I found I could do! In the Table control - Click-Browser I run ExecuteProcess( trtClick ) on a button which sits off-screen/invisible. The button server code is Ajax--Off and it can use PageDisplay() to display a page. Seems a kludge but it works :)

von JP - am 14.06.2016 14:01
Zur Information:
MySnip.de hat keinen Einfluss auf die Inhalte der Beiträge. Bitte kontaktieren Sie den Administrator des Forums bei Problemen oder Löschforderungen über die Kontaktseite.
Falls die Kontaktaufnahme mit dem Administrator des Forums fehlschlägt, kontaktieren Sie uns bitte über die in unserem Impressum angegebenen Daten.