...

View Full Version : how to trigger an event automatically



imi242
03-24-2009, 06:07 PM
Hello all

I have to solve this problem.
I have a disabled field which can be changed by using search help showing the select option. After the user selects his wish, the disabled field contains his selection. I need to trigger an event automatically right after the disabled field is changed. This function triggers the event I need:
BBPSCForm_Submit('SC_REFRESH')

the code at the disabled field looks like this:
<input type=text title="`#GL_ACC`" name="`T_SCREEN_ACCLIST-G_L_ACCT[j].name`" value="`T_SCREEN_ACCLIST-G_L_ACCT[j].value`" maxlength="64" size="11" disabled>

I hope someone can help.
Thanx

Eldarrion
03-24-2009, 06:28 PM
Have you tried using onchange? Example:



<input type="text" onchange="do whatever you want to do" />


Should definitely do the trick.

imi242
03-24-2009, 06:45 PM
It doesnt work, because the change is happening on the search help page.
User clicks on a link to select options. After the selection the user is sent back to the main window. The field is changed (but disabled so it is not possible to change without the search help link). After this I need to trigger the the function with SC_REFRESH event, but I have no event on in the main window.

BTW the BBPSCForm_Submit('SC_REFRESH') works fine if the field is not disabled and using for example an Onlick event.

Eldarrion
03-24-2009, 09:17 PM
Well, in that case you're going to have to use a callback. Considering the distinct lack of code... I'd suggest you go to the following website and read up on it:

http://w3future.com/html/stories/callbacks.xml

Hopefully that helps.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum