There is a bit of a temporary workaround to this if you can’t wait till the 6.1.2 bugfix release that it is hoped the Embedded param issue is fixed in.
I could solve my
issue by bodging the OBJECT\embed tags into a label and getting the flash resource string from a ClassResource.
public class FlashLabelApplication extends Application {
private String objectHTMLStr =
"<OBJECT classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0\" width=\"600\" height=\"500\" id=\"Column3D\" >\n" +
" <param name=\"movie\" value=\"{1}?chartWidth=600&chartHeight=500\" />\n" +
" <param name=\"FlashVars\" value=\"&dataXML=<graph caption='Monthly Unit Sales' xAxisName='Month' yAxisName='Units' showNames='1' decimalPrecision='0' formatNumberScale='0'><set name='Jan' value='462' color='AFD8F8' /><set name='Feb' value='857' color='F6BD0F' /><set name='Mar' value='671' color='8BBA00' /><set name='Apr' value='494' color='FF8E46'/><set name='May' value='761' color='008E8E'/><set name='Jun' value='960' color='D64646'/><set name='Jul' value='629' color='8E468E'/><set name='Aug' value='622' color='588526'/><set name='Sep' value='376' color='B3AA00'/><set name='Oct' value='494' color='008ED6'/><set name='Nov' value='761' color='9D080D'/><set name='Dec' value='960' color='A186BE'/></graph>\">\n" +
" <param name=\"quality\" value=\"high\" />\n" +
" <embed src=\"{1}\" flashVars=\"&dataXML=<graph caption='Monthly Unit Sales' xAxisName='Month' yAxisName='Units' showNames='1' decimalPrecision='0' formatNumberScale='0'><set name='Jan' value='462' color='AFD8F8' /><set name='Feb' value='857' color='F6BD0F' /><set name='Mar' value='671' color='8BBA00' /><set name='Apr' value='494' color='FF8E46'/><set name='May' value='761' color='008E8E'/><set name='Jun' value='960' color='D64646'/><set name='Jul' value='629' color='8E468E'/><set name='Aug' value='622' color='588526'/><set name='Sep' value='376' color='B3AA00'/><set name='Oct' value='494' color='008ED6'/><set name='Nov' value='761' color='9D080D'/><set name='Dec' value='960' color='A186BE'/></graph>\" quality=\"high\" width=\"600\" height=\"500\" name=\"Column3D\" type=\"application/x-shockwave-flash\" pluginspage=\"http://www.macromedia.com/go/getflashplayer\" />\n" +
"</object>";
@Override
public void init() {
Window w = new Window("Flash in a label");
setMainWindow(w);
w.getContent().addComponent(getFlashLabel());
}
public Component getFlashLabel() {
// Get the Flash Resource.
final ClassResource flashResource =
new ClassResource("FCF_Column3D.swf", this.getMainWindow().getApplication());
// Replace some variables in the OBJECT and embed tag - in this case just the flash resource
objectHTMLStr = StringUtils.replace(objectHTMLStr, "{1}", this.getRelativeLocation(flashResource));
// Create XHTML label and add objectHTMLStr as the data
Label flashLabel = new Label();
flashLabel.setContentMode(Label.CONTENT_XHTML);
flashLabel.setPropertyDataSource(new ObjectProperty(objectHTMLStr, String.class));
return flashLabel;
}
}
This could be bad for many reasons I am too naieve to understand but it seems to work !