I have implemented  display superclasses for instances of static text and buttons.

In some cases I want the static text or button to not display, but the return(SKIP) is 
being ignored.

For example,   here is the code for my static text.  The static text still shows on 
the page.

What am I doing wrong?


//[[SPIDER_CLASS BEGIN
public class AISStatusmsg extends spider.visual.CSpStaticText 
        implements spider.event.ISpDisplayListener, ISpHtmlOutputListener
        
//]]SPIDER_CLASS END
{

        public AISStatusmsg()
        {
                super();
        }

        public int init()
        {
                super.init();
                addDisplayListener(this);
                addHtmlOutputListener(this);
                return(PROCEED);
        }

        public int onBeforeDisplayEvent(CSpDisplayEvent event)
        {       
                CSpStaticText statusMsg = (CSpStaticText)event.getSource();
                statusMsg.setHtmlEscaping(false);

                                    //this message is being displayed on the page so I 
know
                                   //it hits here.
                statusMsg.setValue(new CSpString("this is a test"));
                return (SKIP);
        }


        public int onBeforeHtmlOutputEvent(CSpHtmlOutputEvent event)
        {               
                return(SKIP);
        }
        //]]SPIDER_EVENTS END
}
_________________________________________________________________________

For help in using, subscribing, and unsubscribing to the discussion
forums, please go to: http://www.netdynamics.com/support/visitdevfor.html

For dire need help, email: [EMAIL PROTECTED]

Reply via email to