Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.


Code Block
var sessionInterval = 1000 * 25; // milliseconds to minutes
var sessionRefreshURL = "/frevvo/web/login";

refreshFrevvoSession = function () {

   // make the request
   var xmlhttp;
   if (window.XMLHttpRequest) xmlhttp = new XMLHttpRequest(); // IE7+, Firefox, Chrome, Opera, Safari
   else xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); // code for IE6, IE5"GET", sessionRefreshURL + "?sessionRefresh=" + new Date().getTime(), true);

   // set the timer to run again
   setTimeout(refreshFrevvoSession, sessionInterval);
setTimeout(refreshFrevvoSession, sessionInterval); // set the initial timer

In the above Custom js you can also use /frevvo/heartbeat in place of /frevvo/web/login.

Auto Control Validation

 has built-in validation that will instantaneously display an error message, the control background color will turn yellow and you will see a warning icon on the right side of the control when invalid values are entered. For Example, the Quantity control allows only whole numbers. An error message and a  warning icon will display and the background color of the control will change to yellow if a number with a decimal point is entered. The forms designer can restrict users from entering a value with a decimal point using JavaScript. The script below will automatically remove a decimal point from the field and the error message will not display. Similar logic can be used to implement instant validation on other control types as well.