Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Dotted-border Box
Message
 
 
À
16/04/2009 18:43:04
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Divers
Thread ID:
01395217
Message ID:
01395268
Vues:
95
Hi Mark,

For simplicity, the code below assumes that you've transparent shape with transparent borders (Shape1) on the form that defines where a dotted border box should be drawn
WITH Thisform
	lnPosX = .Shape1.Left
	lnPosY = .Shape1.Top

	FOR i=1 TO .Shape1.Width STEP 2
		lnPosX1 = lnPosX + i - 1
		lnPosY1 = lnPosY
		.Line(lnPosX1, lnPosY1, lnPosX1+1, lnPosY1)
		lnPosY2 = lnPosY1+.Shape1.Height-1
		.Line(lnPosX1, lnPosY2, lnPosX1+1, lnPosY2)
	ENDFOR

	FOR i=1 TO .Shape1.Height STEP 2
		lnPosX1 = lnPosX
		lnPosY1 = lnPosY + i - 1
		.Line(lnPosX1, lnPosY1, lnPosX1+1, lnPosY1)
		lnPosX2 = lnPosX1+.Shape1.Width-1
		.Line(lnPosX2, lnPosY1, lnPosX2+1, lnPosY1)
	ENDFOR
ENDWITH
>Is there a Win API to draw a box with a dotted border EXACTLY like
>what surrounds the caption of a clicked checkbox (such as
>when you just clicked this message)?
>
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform