Incident form automatically jumps / scolls to the Activity

puffysleaves
Tera Expert

When most users go to the incident form, the browser immediately jumps to the activity section of the incident form as if the Show Activity Stream button were pressed. This happens when going to an existing incident or creating a new one. I see this happen while impersonating a user while looking at an incident at 100% zoom in the browser. When I look at the same incident with my account in the same browser at the same zoom, everything is fine and the page does not jump. With Chrome, Firefox and IE browsers, I can only get the page to jump down to the activity section with my admin account if I zoom in 125% in any browser. So I'm confused. I've been using the zoom as a temporary solution. Some people zoom out to 90% or 80% in their browser and this jumping behavior stops but that's not a solution for everybody. Most of our users use Firefox and unfortunately IE. I believe this started happening after the upgrade to Helsinki. Why is this happening and how can I stop it?

1 ACCEPTED SOLUTION

We had the same issue but it was due to a onload client script which showfieldMsg method on the one the fields down below. As soon as we open the record the screen scrolls down to that field.



Why don't you remove the activity from the form and see if its happening again if   not then we can narrow down a little bit


View solution in original post

10 REPLIES 10

We had the same issue but it was due to a onload client script which showfieldMsg method on the one the fields down below. As soon as we open the record the screen scrolls down to that field.



Why don't you remove the activity from the form and see if its happening again if   not then we can narrow down a little bit


Ah it was showFieldMsg being called in a UI Policy. Disabling that policy fixed the issue. Maybe we'll use an annotation on the form instead to prevent this auto scrolling. Thank you so much. This issue has been driving people crazy.    


This was also my issue I had a client script under additional comments that use the showfieldMsg method and it would make the browser jump to that message on the form where ever that script was. For me, it was the incident and task forms.

Below is the sample script that was causing the issue.

find_real_file.png

tanxdavid1
Tera Contributor

Experienced similar issue. The fix was to set this system property: glide.ui.scroll_to_message_field to false. 

Display field messages 

An alternative approach to prevent the form from scrolling is to set "Scroll form" to false on the showFieldMsg call of your onLoad client script:

g_form.showFieldMsg('<FIELD_NAME>', '<MESSAGE>', 'info', false);

 

See: https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0690796