I have overridden the case resolve button to call my custom JavaScript. I will call this function custom_resolve_func(). That works fine. When I press the resolve button, custom_resolve_func() is invoked.
I have another function attached to the OnLoad event of a case form.. I will call this function custom_onload_func().That works fine. When I load the form, custom_onload_func() is invoked.
custom_resolve_func() and custom_onload_func() are in the same JS webresource.
My problem is how to have both funcs share data at runtime?
For example, In custom_onload_func() I set a variable global to the JS webresource. When I press the resolve button, invoking custom_resolve_func(), I read the same variable but its as if it never got set in custom_onload_func(). If I give it an initial value at time of declaration, that is the value I get when I read it in custom_resolve_func().
How can both funcs share the same context? I need custom_resolve_func() to be able to access the form context somehow...