Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Centering a checkbox in grid column
Message
From
30/06/2003 22:52:03
 
 
To
26/06/2003 16:12:22
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00804414
Message ID:
00805548
Views:
29
Hi,

Try this solution:

1. You create new class base on CONTAINER control and add CHECKBOX control with it's caption = '' on it. The name of checkbox is chk (Just example).

2. Write following code in INIT event of new class

WITH THIS && container
.Width = .Parent.Width
.Height = .Parent.Parent.RowHeight - 2

.chk.Left = INT((.Width - 15)/2)
.chk.Top = INT((.Height - 15)/2)

.ActiveControl = .chk
ENDWITH

3. Add new class to replace control on column of grid.

Remember set SPARSE property of column is .F.

-----------
Danh,
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform