[Axualize-users] HTML tags in text strings?
Brought to you by:
russwyte
From: Frank B. <fbu...@el...> - 2003-03-07 21:00:46
|
Hi-- I am attempting to put HTML tags into text strings for page headers, text color, etc. with no success. Here is the relevant code for my first attempt: the object-script is declared before my <s:JFrame> tag: <object-script> String s = "<html><h2>Header from an object-script</h2></html>"; return s; </object-script> Within my JFrame, I add a label: <add> <s:JLabel> <object idref="s"/> </s:JLabel> <GridBagConstraints gridx="0" gridy="RELATIVE" ipadx="1" ipady="1" gridheight="1" gridwidth="2" weightx="1" weighty="1"/> </add> This generates a parse error: com.sequenet.axualize.AxualizeException: called in model:testForm at com.sequenet.axualize.handler.ObjectHandler.invokeMethod(ObjectHandler.java:242) at com.sequenet.axualize.handler.ObjectHandler.processMembers(ObjectHandler.java:87) <much stack trace deleted...> Caused by: Sourced file: <Inline eval of: String s = "; > Token Parsing Error: Lexical error at line 2, column 22. Encountered: <EOF> after : "\";": <at unknown location> If I remove the html tags from within the label string in the object-script, it works fine. Second attempt: Tried to just put the html tags within a <string> tag as the parameter to the JLabel: <add> <s:JLabel> <string><html><h2>This is the page header from a string object</h2></html></string> </s:JLabel> <GridBagConstraints gridx="0" gridy="RELATIVE" ipadx="1" ipady="1" gridheight="1" gridwidth="2" weightx="1" weighty="1"/> </add> In this case, I see no errors, but the label does not appear. If I remove the html tags, again, the label shows up as expected. Any suggestions on how to put HTML formatting into labels? Thanks for your help, Frank |