Hi People,

I have a chart on my page:

<div id="list_active_value_card_accounts_table" class="graph"></div>

<script type="text/javascript">

    function requestListActiveValueCardAccounts() {

        var chartHolder = $('#list_active_value_card_accounts_table');

        $.ajax({
            url: '@Url.Content("~/endpoint/
ListActiveValueCardAccounts")',
            dataType: 'json',
            data: { limit: 10 },
            cache: false,
            success: function (result) {
                var data = new google.visualization.DataTable(result);
                var table = new
google.visualization.Table(chartHolder[0]);
                table.draw(data, { showRowNumber: false,
cssClassNames: { tableCell: 'tablefontclass', headerCell:
'tablefontclass'} });

            }
        });
    }
</script>

my Json:

{"cols":[{"id":"Debit","label":"Debit","type":"number"},
{"id":"Credit","label":"Credit","type":"number"},
{"id":"Balance","label":"Balance","type":"number"},
{"id":"ValueCard","label":"ValueCard","type":"string"},
{"id":"CallDate","label":"CallDate","type":"datetime"}],"rows":[{"c":
[{"v":6.75},{"v":20},{"v":13.25},{"v":"280210753455"},{"v": "new
Date(2011,11,19,8,9,13)"}]}]}


The chart fails to show because of Jquery already parsing the dates
into javascript date time, before it is handled by the datatable. The
error I get from jquery is: Object doesn't support property or method
'getTimezoneOffset'  and the chart isn't drawn. This appears to be the
same issue these people are getting:

http://www.ram-solutions.nl/?tag=google-charts-api
http://stackoverflow.com/questions/2823478/populate-google-visualization-datatable-for-a-annotatedtimeline-using-json

Nothing I do seems to fix the issue, has anyone else come across this
or know how to fix it?

I'm using jquery-1.5.1.min.js

Thanks Heaps,
Maxus

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-visualization-api?hl=en.

Reply via email to