Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Transparent Grid
Message
From
15/05/2008 03:03:42
 
 
To
15/05/2008 02:18:47
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
01317225
Message ID:
01317227
Views:
10
>Hi Guys,
>
>Is it possible to make a grid transparent?
>
>Thanks in advance...

Since VFP controls do not have Window Handles, I believe you cannot.
However, you can wrap the grid in a top-level form.

hth
-Stefan
PUBLIC oForm as Form
oForm = CREATEOBJECT('TestForm')
oForm.Show()
RETURN

DEFINE CLASS TestForm as Form
	ShowWindow = 2
	PROCEDURE Load
		CREATE CURSOR temp (test1 Char(10), test2 Int)
		LOCAL i
		FOR i = 1 TO 64
			INSERT INTO temp VALUES ( CHR(i+64), i )
		ENDFOR
		GO TOP
	ENDPROC
	PROCEDURE Init
		DECLARE SetWindowLong In Win32Api ;
			Integer, Integer, Integer
		DECLARE SetLayeredWindowAttributes In Win32Api ;
			Integer, String, Integer, Integer
		SetWindowLong(ThisForm.HWnd, -20, 0x00080000)
		SetLayeredWindowAttributes(ThisForm.HWnd, 0, 120, 2)
	ENDPROC

	ADD OBJECT grdTest as Grid WITH ;
		RecordSource = 'temp', ;
		ColumnCount = 2
	PROCEDURE grdTest.Init
		This.Move(0,0,Thisform.Width,Thisform.Height)
		This.Anchor = 15
	ENDPROC

ENDDEFINE
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform