As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.
New TIBCO Community Coming Soon
In early summer, TIBCO plans to launch a new community—with a new user experience, enhanced search, and expanded capabilities for member engagement with answers and discussions! In advance of that, the current myibi community will be retired on April 30. We will continue to provide updates here on both the retirement of myibi and the new community launch.
What You Need to Know about Our New Community
We value the wealth of knowledge and engagement shared by community members and hope the new community will continue cultivating networking, knowledge sharing, and discussion.
During the transition period, from April 20th until the new community is launched this summer, myibi users should access the TIBCO WebFOCUS page to engage.
How do you set the enter key on the key pad as a tab key in maintain. Most of our users uses the enter key as the tab key. However, in the apps that was developed the enter key is the tab key. I know in modify you can change the settings. Can this also be done in maintain.
Ok - This is pretty straight forward, but it's also brute force. If anyone has a different way, let us know. Basically, if checks to see if the ENTER key is pressed (13), checks the current field position, and moves the cursor to the next field. Please this trigger on the form itself
Mark
function OnForm1_KeyPress ( ) { var kp = window.event.keyCode; var curr = document.activeElement.id; if (kp==13) { if (curr=='Field1_Edit') document.Form1.Field2_Edit.focus(); if (curr=='Field2_Edit') document.Form1.Field3_Edit.focus(); if (curr=='Field3_Edit') document.Form1.Field1_Edit.focus(); } }
Posts: 663 | Location: New York | Registered: May 08, 2003
I've found this to work, particularly where there are many elements on the page.
function KeyPress ( ) {
// change minTabIndex and maxTabindex to the first and last input/editable elements on the form
var minTabIndex=1;
var maxTabIndex=5;
var kp = window.event.keyCode;
if (kp != 13) return;
var currentTabIndex = window.event.srcElement.getAttribute('tabindex');
var numElements = document.forms[0].length;
nextElement = document.forms[0].elements[0];
var minElement = ' ';
var maxElement = ' ';
var nextElement = ' ';
var currElement = ' ';
for(elementnum = 0; elementnum < numElements; elementnum++){
if (document.forms[0].elements[elementnum].getAttribute('tabindex') == minTabIndex) {
minElement = elementnum;
}
if (document.forms[0].elements[elementnum].getAttribute('tabindex') == currentTabIndex) {
currElement = elementnum;
}
if (document.forms[0].elements[elementnum].getAttribute('tabindex') == maxTabIndex) {
maxElement = elementnum;
break
}
if (document.forms[0].elements[elementnum].getAttribute('tabindex') > currentTabIndex) {
nextElement = elementnum;
break
}
}
if (maxElement == currElement) {
document.forms[0].elements[minElement].focus();
return;
} else {
if (nextElement == ' ') {
document.forms[0].elements[maxElement].focus();
return;
} else {
document.forms[0].elements[nextElement].focus();
return;
}
}
}
if(document.captureEvents) document.captureEvents(Event.KEYPRESS);
document.onkeypress = KeyPress;
Make sure your tab order is set up, and then set the minTabIndex and maxTabIndex. Put this code in a .js file and attach it to your form.
If you have an issue with this, come back to me 'cos I know how I set up the maintain forms, so have not tried it with the way others might do it differently, or you may want a bit more explanation.
Alan. WF 7.705/8.007
Posts: 1451 | Location: Portugal | Registered: February 07, 2007
Most of our users uses the enter key as the tab key.
You would be better off to train the users to use the Tab key as it is intended. I can't see where their current behavior is of any value in todays IS/IT world.
On most any web page with a form, the Enter key will submit the form. If you remap the function of the Enter key, you are just reinforcing bad user interface behavior, that will cause them grief down the road.
And, you won't have to figure out how to add Alan's Javascript to your Maintain
Both techniques need to be set up as javascript triggers. If you use my technique do this:
1) Display the form in question 2) Click on the Trigger Tab 3) Select the KeyPress trigger 4) Change trigger type to JavaScript and include my trigger code. You will have to change the names of my objects to reflect the name of your objects.
Mark
Posts: 663 | Location: New York | Registered: May 08, 2003