Bortosky google visualization Code update

You can find the library of Bortosky google visualization in here. As its home page states its a helper types to serialize System.Data.DataTable objects into Javascript Object Notation for use as a Google DataTable in the Google Visualization APIs.

When you go to one of its issue “JSON new Date output now fails parsing” solution provide by Sha…@babajob.com is correct but the source code mentioned in the download link is not updated with the fix.

So as mentioned in the fix please make below code changes in source code.

In file DateGoogleDataColumn.cs line 33

return string.Format("\"Date({0}, {1}, {2})\"",
 d.Year, d.Month - 1, d.Day);

In file DateTimeGoogleDataColumn.cs line 33

return string.Format("\"Date({0}, {1}, {2},
 {3}, {4}, {5})\"",
d.Year, d.Month - 1, d.Day,
 d.Hour, d.Minute, d.Second);

Enjoy Google Charts!

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s