Power table row and cell coloring

@srinivas_anupurapu - You're asking in a thread that has been more than a year since the last post so it's unlikely that the original posters will notice this. I happened to stumble on to this, so I will show you an example I have done.

This configures a power table with alternating light yellow and light green rows by default. If a cell contains a NULL value, then that cell is gray (without changing the rest of the row). If a cell contains a date too far in the future, the cell is light blue. If the cell contains a date whose hour is set to 12 then that cell is red.

def configureCell(self, value, textValue, selected, rowIndex, colIndex, colName, rowView, colView):
	import datetime
	if colIndex > 0 and value == None:
		return {'background': '#D5D5D5'}
	try:
		if colIndex > 0 and  value > datetime.datetime(2099,12,31):
			return {'foreground': '#3CCAE7',
					'background': '#3CCAE7'}
		elif colIndex > 0 and value.hours == 12:
			return {'background': '#FF6858'}
		elif selected:
			return {'background': self.selectionBackground}
		elif rowView % 2 == 0:
			return {'background': '#CCFFCC'}
		else:
			return {'background': '#FAFFCC'}
	except:
		if selected:
			return {'background': self.selectionBackground}
		elif rowView % 2 == 0:
			return {'background': '#CCFFCC'}
		else:
			return {'background': '#FAFFCC'}
		

Here's what it looks like...