Web Apps – add timeout check to timecard validation

When we first went live with web apps, our users were experiencing some pretty quick time outs. After tweaking some IIS settings, our users are now getting a full 60 minutes of inactivity before their session is terminated. However, one ugly part of the time out is that if you had the grid loaded when you were timed out, you were allowed to keep entering time. You would not be notified of your timed out session until you went to save your timecard. This led to a lot of data loss and unhappy employees.

To fix this, I added a timeout check to the ValidateSuccess function. This way, if a user is in a timed out state, they will be notified as soon as they enter data into the timecard grid rather than waiting until it’s time to save!

function ValidateSuccess(data, textStatus, xhr, row) {
    //MSDE added 11/13/18 to test, so users don't keep entering data that won't be saved
    if (DidTimeoutOccur(data) == 1) {
        // The 'T' tells the page it needs to display the timeout message.

As you can see, now if a user is in a timed out state, as soon as they enter something into the grid, they will be redirected to the logout page. 

Feel free to share...

Leave a Reply

Close Menu