Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grid Border Color
Message
De
30/09/2018 05:43:27
Walter Meester
HoogkarspelPays-Bas
 
 
À
30/09/2018 05:39:34
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows 10
Database:
MS SQL Server
Divers
Thread ID:
01662372
Message ID:
01662403
Vues:
51
Hi Koen,

In your example the shape is underneath and arround the grid, it does not replace the border (just take a screenshot, load it into paint and magnify it).
The lines need to be ON TOP of the grid border. You can't use a shape to do that because you won't be able to click into the grid.

Walter


>>Koen,
>>
>>You have drawn a border arround the grid, you did not replace the border.
>>You need to draw lines because if you use a shape on top of the grid border, you won't be able to click into the grid.
>
>Walter,
>
>I dont have have that experience, I can cllick on the grid although there is a shape around my grid. Please try my example.
>
>Regards,
>
>Koen
>
>>
>>Walter,
>>
>>
>>>>>Hi!
>>>>>
>>>>>Is ist possible to set the Border Color of the GridObject?
>>>>
>>>>I've seen solutions where there'd be a line around the grid. Four lines, that is, with some distinct color (depending on focus that would change), while the gridlines were some lighter shade of gray. Looks good, to be honest. And the code isn't too complicated, even with a few bindevent()s to support resizing.
>>>
>>>
>>>Dragan,
>>>
>>>I think it is better to use a shape instead of 4 lines, less code and easy to maintain, colour thickness etc and it (can) anchor with the form/gdrid
>>>
>>>
>>>**************************************************
>>>*-- Class:        myform (d:\foxexamples\grid\gridwithcoloredborder\gwcb.vcx)
>>>*-- ParentClass:  form
>>>*-- BaseClass:    form
>>>*-- Time Stamp:   09/29/18 06:41:05 PM
>>>*
>>>DEFINE CLASS myform AS form
>>>
>>>
>>>	Top = 0
>>>	Left = 0
>>>	Height = 277
>>>	Width = 405
>>>	DoCreate = .T.
>>>	Caption = "Form"
>>>	BackColor = RGB(255,255,255)
>>>	Name = "myform"
>>>
>>>
>>>	ADD OBJECT shape1 AS shape WITH ;
>>>		Top = 24, ;
>>>		Left = 36, ;
>>>		Height = 208, ;
>>>		Width = 330, ;
>>>		Anchor = 15, ;
>>>		BorderStyle = 6, ;
>>>		BorderWidth = 2, ;
>>>		Curvature = 0, ;
>>>		BorderColor = RGB(255,0,0), ;
>>>		Name = "Shape1"
>>>
>>>
>>>	ADD OBJECT grid1 AS grid WITH ;
>>>		Anchor = 15, ;
>>>		Height = 204, ;
>>>		Left = 38, ;
>>>		Top = 26, ;
>>>		Width = 326, ;
>>>		Name = "Grid1"
>>>
>>>
>>>	PROCEDURE Load
>>>		IF !USED('customers')
>>>			USE HOME(2)+'\northwind\customers' SHARED
>>>		endif
>>>	ENDPROC
>>>
>>>
>>>ENDDEFINE
>>>*
>>>*-- EndDefine: myform
>>>**************************************************
>>>
>>>
>>>Regards,
>>>
>>>Koen
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform