aspose file tools*
The moose likes JSF and the fly likes Object expected Error when I use a4j:ajax happens only IE8 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "Object expected Error when I use a4j:ajax happens only IE8" Watch "Object expected Error when I use a4j:ajax happens only IE8" New topic
Author

Object expected Error when I use a4j:ajax happens only IE8

tony altaico
Greenhorn

Joined: Jan 31, 2009
Posts: 21
Hello

For a job, I have to use only IE8 as a browser. When I use a4j:ajax event it gives me "Object expected" error and in IE8 Developer tools it tells that this "Object Expected" comes from rich:messages that I used before.

This issue only happens in IE8 and it happens when I use a4j:ajax event. Even when I use only <a4j:ajax event="dblclick"> without any other tag, I still come across with "Object Expected" javascript error which comes from rich:messages .. You can see code of the exact poing where error happens and my <rich:message> declaration below.




Error :
Object Expected
;new RichFaces.ui.Message("j_idt374",{"forComponentId":"sarfTuruId","showSummary":false,"showDetail":true} )

Rich Message declaration:


Any assistance you can provide would be greatly appreciated.

Cheers
Altaico
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16058
    
  21

Just a guess, but I suspect that your references to the open and close button controls are incorrect. When coding JavaScript, you have to reference the HTML IDs, which are usually not quite the same as the JSF IDs, since JSF supports naming containers such as forms, dataTables, and so forth. The JavaScript (HTML) name is a concatenation of the simple JSF ID plus the IDs of its containers. When a name is in a for like "j_12345" that means that that particular control/container was not supplied with an explicit ID and therefore JSF synthesized an ID. Unfortunately, these synthetic IDs are prone to change without notice, so it's best to supply an explicit ID on all containers plus on any controls that you'd like to be able to easily identify.


Customer surveys are for companies who didn't pay proper attention to begin with.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Object expected Error when I use a4j:ajax happens only IE8