Home
TeamSite
init() method calling more than one time
Pummy
Hi,
I have encountered a strange Problem with FormAPI Validation.
I have registered init() method on FormInit method. And have few functions inside this functions like.... Resizepane(), setReadonly().. and few more which i want to be called on init() method.
This works perfectly fine when my new DCR loads. Everything goes as expected. BUT.. the things gets worse when click on any on the container names onleft hand side of my DCT. Each time i shift from one container to another to my surprise init() method is called each time.
So.. my DCT looks really messed up with same replicant item being shown 2 times with in container and so.. and the Items in container cannot be moved up and down.
My problem will be resloved if the init() is called only once. I am not able to figure out why this strange behaviour is happening.
Can some one help me out to resolve this issue. Thanks a million in Advance..
Regards,
Praveen.
Find more posts tagged with
Comments
Pummy
More addition info to my Problem.
This is first statement in my JS.
IWEventRegistry.addFormHandler("onFormInit",init_override);
and i have this function defined in bottom of the JS.
===========================================
function init_override() {
alert("Indside Init of Popup.js");
IWDatacapture.setIsModified (true);
//Call the Functions on onLoad Event of DCT to set Initial Values
//Call JS to add DCT Help Button added by Praveen
onlineHelpCall();
resizeNav();
setReadProperty();
setCalloutEvents();
setEventHandlers();
//Register EventHandler for Save,SaveDone and Finish Events
IWEventRegistry.addFormHandler("onClose",closefunc);
}
============================================
Sailesh
Check with Teamsite team from Noida TechM they faced a similar thing some time back. Contact Chetan Sethi.