Hi All,I want to capture the event generated when the "+" button of a replicant contianer is clicked. The onReplicantAdded event is not working since the Teamsite version I use is 6.1. I tried with the onItemAdded event as follows,parent.IWDCEventRegistry.addListener("onItemAdded", ReplicantAdded);function ReplicantAdded(typeItem){.....Function1();Function2();.....}Upto this its working fine... but as soon as I add any methods of "typeItem" parameter as typeItem.getName(), or even as I tried to trace the parent item, the page is being loaded with a javascript error stating " the method is not supported by the object".. function ReplicantAdded(typeItem){alert(typeItem.getName());.....Function1();Function2();.....}Please any body give some suggestions on this...Thanks --Sanu
Hi All, I want to capture the event generated when the "+" button of a replicant contianer is clicked. The onReplicantAdded event is not working since the Teamsite version I use is 6.1. I tried with the onItemAdded event as follows, parent.IWDCEventRegistry.addListener("onItemAdded", ReplicantAdded);function ReplicantAdded(typeItem){ ..... Function1(); Function2(); .....} ...Please any body give some suggestions on this...Thanks --Sanu
parent.IWDCEventRegistry.addListener("onItemAdded", ReplicantAdded);function ReplicantAdded(typeItem){ ..... Function1(); Function2(); .....}
Hi All, I want to capture the event generated when the "+" button of a replicant contianer is clicked. The onReplicantAdded event is not working since the Teamsite version I use is 6.1. I tried with the onItemAdded event as follows,parent.IWDCEventRegistry.addListener("onItemAdded", ReplicantAdded);function ReplicantAdded(typeItem){ ..... Function1(); Function2(); .....}Upto this its working fine... but as soon as I add any methods of "typeItem" parameter as typeItem.getName(), or even as I tried to trace the parent item, the page is being loaded with a javascript error stating " the method is not supported by the object".. function ReplicantAdded(typeItem){//alert(typeItem.getName()); alert(getXPath(typeItem)); ..... Function1(); Function2(); .....}Please any body give some suggestions on this...Thanks --Sanu
Well - to begin with, the replicant handler events were added in 6.5 - so if you're using 6.1 you're basically out of luck unless you figure out some completely unsupported hack.I can only assume from the above that you tried to reverse engineer something to arrive at IWDCEventRegistry.addListener() - as that is not a supported function in FormAPI.Then there's onItemAdded - which also does not exist, instead there's onItemChanged - so I have to assume that you found this event listed somewhere - but it doesn't mean that it does what you want it to do.I suggest that if you really need this functionality, you put in for an upgrade - to at least 6.5 if not 6.7.1
my requirements are :i want to know the parent item of the typeItem argument and perform according to that. there are many instances of different containers in the DCT.ISCBorisB, the highlighted code is also not working. its also giving a javascript issue: "Object expected". my code snippet is ,function ReplicantAdded(typeItem){var parent = IWDatacapture.getItem(typeItem.getName() + "/..").getName();if(parent eq "Parent1"){................}elseif(parent eq "Parent2"){............}else{.............}}for this code i m getting java script error "method not supported by the object".
function ReplicantAdded(typeItem) { alert(typeItem.name); alert(getXPath(typeItem));}
thanx very much ISCBorisB,I tried the code snippet..function ReplicantAdded(typeItem) { alert(typeItem.name); alert(getXPath(typeItem));}I m getting the first alert as replicant name (contact_details) though I expected the replicant instance (contact_details[1]); for the second one(getxpath), its showing the same error... "object expected". do I need to call that method by using some object? if yes which one?. I tried, IWDatacapture.getXPath(), parent.getXPath(), this.getXPath().. now what else?from the first line, "typeItem.name" property ,my requirement won't get satisfy since I need the parent item name. I tried my best to get the parent item name with the following wild guesses..typeItem.pathtypeItem.xpathtypeItem.parentbut of no use...