jQWidgets Forums
jQuery UI Widgets › Forums › Chart › Chart Bar Error
This topic contains 2 replies, has 2 voices, and was last updated by Autthpon 10 years, 9 months ago.
-
AuthorChart Bar Error Posts
-
Can you help me, please?
I’m setting bar graph.But appear meet error => Invalid value for <stop> attribute offset=”undefined%”
I’m not to cause and solution this error.Helpers.JqWidgets.setGraphBarDataSource = function (sGraphID, aData, sDataField, sDisplay, sSeries, sBaseUnit, iSetLinesInterval, iInterval, bShowRegen, sTitle, sSubTitle, sXTitle, sYTitle, iXLabelRotation, iXTextOffset, iYTextOffset, bShowBorder) { var jDiv = $(sGraphID.toHtmlId()); //Get DataFields if (aData.length > 0) { var source = { datatype: "array", datafields: [ {name: sDisplay}, {name: sSeries} ], localdata: aData }; var dataAdapter = new $.jqx.dataAdapter(source, { async: false, autoBind: true, loadError: function (xhr, status, error) { alert('Error loading "' + source.url + '" : ' + error); } }); bShowBorder = Helpers.General.isNullOrUndefinedOrEmpty(bShowBorder) ? false : bShowBorder; // prepare jqxChart settings var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec']; var oSettings = { title: sTitle, description: sSubTitle, showLegend: Helpers.General.isNullOrUndefinedOrEmpty(bShowRegen) ? true : bShowRegen, enableAnimations: true, showBorderLine: bShowBorder, padding: { left: 5, top: 0, right: 20, bottom: 0 }, titlePadding: { left: 90, top: 0, right: 0, bottom: 10 }, source: dataAdapter, categoryAxis: { // baseUnit: sBaseUnit, // type: 'date', dataField: sDisplay, description: sXTitle, textRotationAngle: Helpers.General.isNullOrUndefined(iXLabelRotation) ? 0 : iXLabelRotation, textRotationPoint: 'right', // textOffset: {x: Helpers.General.isNullOrUndefinedOrEmpty(iXTextOffset) ? 5 : iXTextOffset, y: Helpers.General.isNullOrUndefinedOrEmpty(iYTextOffset) ? -25 : iYTextOffset}, showGridLines: true, formatFunction: function (value) { switch (sBaseUnit.toLowerCase()) { case 'year': return value.getFullYear(); break; case 'month': var aMonth = value.toString().split('-'); var dMonth = new Date(aMonth[0], aMonth[1]); return months[dMonth.getMonth() - 1]; break; case 'hour': case 'minute': return value.getDate().toString().padLeft(2, '0') + '-' + months[value.getMonth()] + '-' + value.getFullYear() + ' ' + value.getHours().toString().padLeft(2, '0') + ':00'; break; case 'day': return value.getDate() + '-' + months[value.getMonth()] + '-' + value.getFullYear(); default: return value; } }, toolTipFormatFunction: function (value) { switch (sBaseUnit.toLowerCase()) { case 'hour': case 'minute': return value.getDate() + '-' + months[value.getMonth()] + '-' + value.getFullYear() + ' ' + value.getHours() + ':00'; case 'year': case 'day': return value.getDate() + '-' + months[value.getMonth()] + '-' + value.getFullYear(); case 'month': var aMonth = value.toString().split('-'); var dMonth = new Date(aMonth[0], aMonth[1]); return months[dMonth.getMonth() - 1]; default: return value; } } }, colorScheme: 'scheme01', seriesGroups: [ { type: 'column', columnsGapPercent: 100, // orientation: 'horizontal', /*Bar Graph*/ valueAxis: { description: sYTitle, unitInterval: getMaxMinFromArray(aData, {dataField: sSeries, displayText: sBaseUnit}, iInterval)["Interval"], displayValueAxis: true }, series: [ { dataField: sSeries, displayText: sBaseUnit } ] } ] }; // setup the chart jDiv.jqxChart(oSettings); jDiv.css('visibility', 'visible'); } };
Hi Autthpon,
The provided information is not sufficient for testing your scenario.
If you report an issue regarding our products, please include the following information in your post:
– jQuery version, jQWidgets version, device type(PC, Mobile), browser name and version.
– Please, provide step by step instructions on how to reproduce the reported issue and provide a small sample in jsfiddle.net which demonstrates it.Best Regards,
Peter StoevjQWidgets Team
http://www.jqwidgets.com/I’m sorry I can not give you an example.
But I found some cases that may be. I’m use old version and can not upgrade to new version.
I have discovered the problem is jqwidget call the jquery version that does not exist. -
AuthorPosts
You must be logged in to reply to this topic.