Page 1 of 1

Input string was not in a correct format.Error data binding.

Posted: Mon Feb 11, 2008 9:16 am
by 13047867
Hi,

I have 1 .Net DataTable and this table have 2 column like a

(type string) , (type int)
NAME , Value
ABC , 112
DEF , 255
GHI , 315
JKL , 95

When i try to bind series from datatable. Getting "Input string was not in a correct format." error.

Code: Select all

Steema.TeeChart.Styles.Pie oPieSeries = new Steema.TeeChart.Styles.Pie();
                    oPieSeries.XValues.DataMember = sXValueDataMember;
                    oPieSeries.XValues.DateTime = isXValueDate;
                    oPieSeries.YValues.DataMember = sYValueDataMember;
                    oPieSeries.Transparency = int.Parse(sTransparency);
                    oPieSeries.Title = sSeriesName;
                    oPieSeries.Color = SeriesColor;
                    oPieSeries.Marks.Visible = bool.Parse(sMarksVisible);
                    oPieSeries.Marks.Transparency = int.Parse(sMarksTransparency);
                    oPieSeries.Marks.Font.Size = int.Parse(sMarksFontSize);
                    oPieSeries.ColorEach = bool.Parse(sisColorEach);
                    oPieSeries.Circled = true;
                    oPieSeries.Pen.Visible = true;
                    oPieSeries.DefaultNullValue = 0;

                    if (sAxisPenWidth != "0") oPieSeries.CustomVertAxis = axis1;
                    try
                    {
                        oPieSeries.DataSource = oData; //<<<Error at here
                        ch1.Series.Add(oPieSeries);
                    }
                    catch (Exception)
                    {

                    }
And i want to say/ask something. This chart is very porfessional tool. But Tutorials and Helps is not like. How many developer using ADO.Net Data Adapter Wizard or FillSampleValue(10). Please add professinal bindings Sample to Tutorials etc.

Thank you.

Posted: Tue Feb 12, 2008 9:38 am
by narcis
Hi Solutions Gallery BV,

Could you please try doing as in the example Christopher Ireland posted here?

If the problem persists, could you please post or send us a simple example project we can run "as-is" to reproduce the problem here?

You can either post your files at news://www.steema.net/steema.public.attachments newsgroup or at our upload page.
And i want to say/ask something. This chart is very porfessional tool. But Tutorials and Helps is not like. How many developer using ADO.Net Data Adapter Wizard or FillSampleValue(10). Please add professinal bindings Sample to Tutorials etc.
Ok, I'll add your request to our wish-list to be included in future versions. You may also be interested in the instructions for using TeeChart using BindingSource I posted at this thread.