Enabling Key Free automatically when a document is opened is helpful in certain indexing scenarios. A simple rule can be defined to trigger Key Free when the viewer is opened. Note that this behavior is equivalent to the user clicking the button themselves.

As implemented below, this rule wait’s 2 seconds for the document viewer to load before triggering the Key Free process. By using $$inject.properties.document.hash we are able to control the viewer in a way that ensures Key Free is only loaded once on each document in the current viewer session. So if a user had multiple documents selected and opened, the first document would Key Free automatically, clicking the Next Document button would trigger Key Free on the second document. Clicking the Previous Doc button would not trigger Key Free again on the first document since that document had already been opened in this viewer session.

var viewHash = 'viewed-'+$$inject.properties.document.hash;
if(!sessionStorage.getItem(viewHash)) {
  sessionStorage.setItem(viewHash, true)
  return "Key Free Started Automatically";
return "Key Free Start Aborted";

Enabling KFI by default can have negative consequences to the overall performance of a GlobalSearch environment, and can lead to a poor user experience. If you intend on enabling this feature as a default option, we strongly encourage the implementation of additional controls to ensure optimal system and user performance.

  • Only enable the feature for users whose workflow demands it.

  • Attempt to control WHEN this behavior is enable. Only on specific archives, only when specific fields contain a given status or value.