Bug 176299 Can't open chart xml files saved by examples view using Standalone builder
Open the chart examples view Pick a chart Save the model to a .chart fie Run the example chartwizardstandalonelauncher opening that .chart file An exception is thrown: Exception in thread "main" java.lang.NullPointerException at org.eclipse.birt.chart.ui.util.ChartUIUtil.checkDataDefinition(ChartUIUtil.java:381) at org.eclipse.birt.chart.ui.util.ChartUIUtil.checkDataBinding(ChartUIUtil.java:361) at org.eclipse.birt.chart.ui.swt.wizard.TaskSelectType.doLivePreview(TaskSelectType.java:1315) at org.eclipse.birt.chart.ui.swt.wizard.TaskSelectType.refreshChart(TaskSelectType.java:1152) at org.eclipse.birt.chart.ui.swt.wizard.TaskSelectType.placeComponents(TaskSelectType.java:201) at org.eclipse.birt.chart.ui.swt.wizard.TaskSelectType.createControl(TaskSelectType.java:176) at org.eclipse.birt.core.ui.frameworks.taskwizard.WizardBase$WizardBaseDialog.switchTask(WizardBase.java:817) at org.eclipse.birt.core.ui.frameworks.taskwizard.WizardBase.switchTo(WizardBase.java:231) at org.eclipse.birt.chart.ui.swt.wizard.ChartWizard.switchTo(ChartWizard.java:259) at org.eclipse.birt.core.ui.frameworks.taskwizard.WizardBase$WizardBaseDialog.initializeBounds(WizardBase.java:659) at org.eclipse.jface.window.Window.create(Window.java:430) at org.eclipse.jface.dialogs.Dialog.create(Dialog.java:1111) at org.eclipse.birt.core.ui.frameworks.taskwizard.WizardBase$WizardBaseDialog.create(WizardBase.java:669) at org.eclipse.jface.window.Window.open(Window.java:785) at org.eclipse.birt.core.ui.frameworks.taskwizard.WizardBase.open(WizardBase.java:104) at org.eclipse.birt.chart.ui.swt.wizard.ChartWizard.open(ChartWizard.java:212) at org.eclipse.birt.core.ui.frameworks.taskwizard.WizardBase.open(WizardBase.java:117) at ChartWizardLauncher.launch(ChartWizardLauncher.java:97) at ChartWizardLauncher.main(ChartWizardLauncher.java:170) Here is how to fix it: Saving the chart clears the runtime series. But if there is only one series in the seriesdefinition, that leaves nothing, making an invalid model. In that case (one single series), it should clear the dataset of the series. The chart builder should be enhanced to open those charts without series, or at least open and show an error asking to add a series. right now it doesn't even open.
chart/org.eclipse.birt.chart.examples/src/org/eclipse/birt/chart/examples/view/models/MDialSRegionMeter.java
.getMinorGrid( )
				.getTickAttributes( )
				.setColor( ColorDefinitionImpl.RED( ) );
		seDial3.getDial( )
				.getMinorGrid( )
				.setTickStyle( TickStyle.BELOW_LITERAL );
		seDial3.getDial( )
				.getScale( )
				.setMin( NumberDataElementImpl.create( 0 ) );
		seDial3.getDial( )
				.getScale( )
				.setMax( NumberDataElementImpl.create( 180 ) );
		seDial3.getDial( ).getScale( ).setStep( 30 );
		seDial3.getLabel( )
				.setOutline( LineAttributesImpl.create( ColorDefinitionImpl.GREY( )
						.darker( ),
						LineStyle.SOLID_LITERAL,
						1 ) );
		seDial3.getLabel( ).setBackground( ColorDefinitionImpl.GREY( )
				.brighter( ) );
		seDial3.setSeriesIdentifier( "Speed 3" );
		dChart.setDialSuperimposition( true );
		sdBase.getSeriesDefinitions( ).add( sdOrth );
		sdOrth.getSeries( ).add( seDial1 );
		sdOrth.getSeries( ).add( seDial2 );
		sdOrth.getSeries( ).add( seDial3 );
		return dChart;
	}
}