I have a simple bar graphic with just one serie. When adding a second serie component to the form, I think I set the properties correctly: chart, datasource, datafielddata and datafieldtitle.
The application stops running with this error messages:
PHsPeed exception report.
2022-06-01 13:33:06 | (error 999 in line  of file )
2022-06-01 13:33:06 |runtime error: [error: call to a member function registerserie() on null in c:\phspeed\xampp\htdocs\ceda\_libs\test_dbchartdbserie_2.php:20
#0 c:\phspeed\xampp\htdocs\_libs\php\spapplication.php(347): test_dbchartdbserie_2->__assign(object(test))
#1 c:\phspeed\xampp\htdocs\ceda\test.php(274): spapplication->init('m', array, array, array)
When checking the properties AFTER running the form, the values are empty again (the chart, datasource, datafielddata and datafieldtitle values are empty).
If I remove the serie component the form runs again.
PHsPeed V2.1.0 B20 - X64
Under Windows 11 Pro Spanish x64
As the sample on this website is using the same version, I wonder what is going wrong. Can you create a small failing sample and send it to support? We'll have a look.
Under version 2.2 the error still shows.
But I found that adding a DBGrid to the form solves the error.
So, if you have an empty form and added
- a DBTable
- a DataSource
- a Chart
- a chartDBSerie
If you set the values for the "chart", "datasource", "datafieldtitle" and "datafielddata" properties in the chartDBSerie, the dissapear when you save/run the form, and you get the registerSerie() error.
But if you add a DBGrid to the form, and THEN set the chartDBSerie properties, they work correctly.
Thnx. We will try to replicate the issue, and fix it.