Other OutSystems sites...
OutSystems Website
About Agility Blog
OutSystems Network
Login
Signup
Forums
Academy
Forge
Ideas
Forums
›
Technology & Integration
›
after client validation
after client validation
Filipe Lourenço
Rank: #120
Posted on 2012-05-25
thumbs_up_ico
0
thumbs_down_ico
0
reply
post_link_ico
How to do some javascript after the edit record client validation?
Rebecca Hall
Rank: #50
Posted on 2012-05-25
thumbs_up_ico
0
thumbs_down_ico
0
reply
post_link_ico
If I need to run code after the client validation, I usually use the "WidgetClick" button and associate the javascript that needs to be ran with the button / link.
Filipe Lourenço
Rank: #120
Posted on 2012-05-25
thumbs_up_ico
0
thumbs_down_ico
0
reply
post_link_ico
No i need to do it without posting to server
Rebecca Hall
Rank: #50
Posted on 2012-05-25
thumbs_up_ico
0
thumbs_down_ico
0
reply
post_link_ico
You can set the action of the button to "ajax" so that it doesn't post back to the server. The widget click will trigger the onclick event of the button or link.
João Rosado
Rank: #35
Posted on 2012-05-25
thumbs_up_ico
0
thumbs_down_ico
0
reply
post_link_ico
Hi,
Actually Filipe is right, even if the button is Ajax there is a small request to the server and the "Widget Click" command is sent to the browser.
As for the initial problem, what exactly you what to do in the page?
You probably could wrap the validator method ..but since that is not an API it could break in the future if we decide to change the rendering of the validators.
Regards
João Rosado
Paul Lucas
Rank: #734
Posted on 2012-05-28
thumbs_up_ico
0
thumbs_down_ico
0
reply
post_link_ico
zipzap wrote
:
How to do some javascript after the edit record client validation?
I've found you are able to execute client-side javascript against buttons/links etc where the On Click Method set to "Ajax"
Create an "onclick" Extended Property and in the value place your javascript eg
"
var ec = extendit.vw.dealerportal.example_class; if (!ec.validateForm()) {return false;};
"
Here I am just calling a function that I have included in my project. If you dont return "false", it will submit the form.
ta
paul
Fern Grey
Rank: #1803
Posted on 2012-05-28
thumbs_up_ico
0
thumbs_down_ico
0
reply
post_link_ico
How to do some javascript after the edit record client validation?
I've found you are able to execute client-side javascript against buttons/links etc where the On Click Method set to "Ajax"
Create an "onclick" Extended Property and in the value place your javascript eg
"
var ec = extendit.vw.dealerportal.example_class; if (!ec.validateForm()) {return false;};
"
Here I am just calling a function that I have included in my project. If you dont return "false", it will submit the form.
Quick Reply
Notify me by email when someone answers to my post
attachment
Choose File
No file chosen
Submit
Login to reply
Something on your mind?
Login to Start a Discussion
Top Forums Posters
Gonçalo Martins
Ricardo Silva
Charles Colaço
Richard Pearson
Davide Marquês
Statler & Waldorf
Justin James
David Chen
JD
Robert Chanphakeo
See leaderboard
Online Training
On-demand video lessons to help you learn at your own pace.
Learn More