> Here is link to change the color of form's title bar. But the problem is with this api is its changing all windows's titile bar. Can anybody improve it so it will effect only vfp.! :)
>
>
http://www.tek-tips.com/faqs.cfm?fid=6071>
> Anil
>
My Blog"There are usually many ways to skin a Fox ..." -Malcolm GreeneHere's another idea from this site below:
http://www.foxdevsd.org/ftp/Newsletters/Newsletter_2001_12.txtI wrote this code based on that idea, have fun!
Local oForm
oForm = Createobject("TestForm")
oForm.Show(1)
Return
Define Class TestForm As Form
Height = 200
Width = 250
TitleBar = 0
BorderStyle = 1
AutoCenter = .T.
Add Object Container1 As ConTitle
Procedure Init
This.Container1.AddObject('Cont1','ConMax')
This.Container1.Cont1.Left = This.Width - This.Container1.Cont1.Width
Endproc
Procedure Container1.DblClick
This.Parent.WindowState = Iif(This.Parent.WindowState = 0,2,0)
Thisform.Container1.Cont1.Left = Thisform.Width - Thisform.Container1.Cont1.Width
Endproc
Enddefine
Define Class ConTitle As Container
Width = Sysmetric(1)
SpecialEffect = 0
BorderWidth = 0
Height = 20
BackColor = Rgb(245,105,205)
Add Object LblTitle As Label With ;
Caption = ' Double Click Me', ;
BackStyle = 0, ForeColor = Rgb(255,255,255), FontBold = .T.
Procedure LblTitle.DblClick
This.Parent.Parent.Container1.DblClick
Endproc
Enddefine
Define Class ConMax As Container
Width = 15
Height = 20
SpecialEffect = 0
BackColor = Rgb(145,045,205)
Left = 30
Visible = .T.
Add Object LblClose As Label With ;
Caption = ' X', BackStyle = 0, ForeColor = Rgb(255,255,255), FontBold = .T.
Procedure LblClose.Click
This.Parent.Parent.Parent.Release
Endproc
Enddefine
(coffee)
DeepLogic Computers & Software / Acer Lending Investor