Thanks.... that fixed me up. Off to learning firing events.
--wg
On Oct 25, 4:24 am, VizGuy <[email protected]> wrote:
> Replace
> data.setCell(0, 5,'R', {'className': 'bold-font'});
> with
> data.setCell(0, 5,'R',* 'R'*, {'className': 'bold-font'});
> or something else for the formatted value.
> In your code you just omitted this parameter, and so the custom properties
> are taken as the formatted value.
> Regards,
> VizGuy
>
>
>
> On Sat, Oct 24, 2009 at 7:41 PM, Winnie <[email protected]> wrote:
>
> > I was simply trying to enhance my already working viz table script to
> > change a table cell to bold font (conditionally from php)..... Other
> > cssClassNames are working. Here's the code:
>
> > <html>
> > <head>
> > <style>
> > .white-font {color:white; background-color:green; }
> > .green-font {color:green; font-weight: bold; }
> > .bold-font {color:green; font-weight: bold; }
> > .black-font {color:black; }
> > .font-hsize {font-size: 60%; line-height: 60%; }
> > .font-csize {font-size: 10px;}
> > </style>
>
> > <script type="text/javascript" src="http://www.google.com/jsapi"></
> > script>
> > <script type="text/javascript">
> > google.load('visualization', '1', {packages:['table']});
> > google.setOnLoadCallback(drawTable);
>
> > function drawTable() {
> > var cssClassNames = {
> > 'headerRow': '',
> > 'tableCell': 'black-font font-csize'};
> > var options = {'showRowNumber': true, 'allowHtml': true,
> > 'cssClassNames': cssClassNames};
> > var data = new google.visualization.DataTable();
> > data.addColumn('string', 'RUN_GROUP');
> > data.addColumn('string', 'PARM_DATE');
> > data.addColumn('string', 'JOBNAME');
> > data.addColumn('number', 'THREAD');
> > data.addColumn('number', 'RUN');
> > data.addColumn('string', 'STATUS');
> > data.addColumn('string', 'START_TIME');
> > data.addColumn('string', 'END_TIME');
> > data.addColumn('string', 'ELAPSED');
> > data.addRows(1);
> > data.setCell(0, 0,'DAILY');
> > data.setCell(0, 1,'2009/10/23');
> > data.setCell(0, 2,'LOAD_SCORECARD_BILLING');
> > data.setCell(0, 3,0);
> > data.setCell(0, 4,1);
> > data.setCell(0, 5,'R', {'className': 'bold-font'});
> > data.setCell(0, 6,'2009/10/24 11:26 am');
> > data.setCell(0, 7,'');
> > data.setCell(0, 8,'000:42:07');
> > var table = new google.visualization.Table(document.getElementById
> > ('table_div'));
> > table.draw(data, options);
> > }
> > </script>
> > </head>
> > <body> <h3>DWPRD Active Jobs</h3><h5>Google Viz Table</h5>
> > <div id='table_div'></div>
> > </body>
> > </html>- Hide quoted text -
>
> - Show quoted text -
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---