Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Inserting a column in a grid
Message
From
13/07/2001 15:04:49
 
 
To
13/07/2001 11:28:03
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00528362
Message ID:
00530447
Views:
20
Hi Trey.

>> Yes, but then the colors aren't dynamic.
With my code, when you move columns around (even columns added on the fly - which I was under the assumption Julian was after), the columns are always alternating blue/white. <<

Good point. I had missed that. However, unless he is allowing is users to add columns to the grid on the fly at runtime, this code in the grid's init will do the trick:
FOR EACH loColumn IN This.Columns
  lcColumn = Strtran(Sys(1272, loColumn), Lower( ThisForm.Name ), "_screen.Activeform" )
  loColumn.DynamicBackColor = "IIF(" + ;
	 	lcColumn + ".ColumnOrder%2=0,RGB(255,255,255),RGB(0,0,255))"
ENDFOR
Marcia
Previous
Reply
Map
View

Click here to load this message in the networking platform