Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Change BackStyle of all labels on all forms.
Message
From
25/07/2000 04:33:44
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Title:
Change BackStyle of all labels on all forms.
Miscellaneous
Thread ID:
00396482
Message ID:
00396482
Views:
44
I want to do the above...
I tried the global scx changer in the files section with the following code:
USE getfile('scx')
*

go top
DO WHILE NOT EOF()
	IF INLIST(UPPER(CLASS),'LABEL','EMBOSSEDLABEL','TEXTBOX','EDITBOX')
		
		mfind = 'BackStyle'
		mreplacewith = ' = 0'
		=fixit(mfind,mreplacewith)
	ENDIF

	SKIP

ENDDO

use


*********************************
FUNCTION fixit()
PARA mfind,mreplacewith
*
mpos = AT(mfind,properties)
IF mpos > 0
	mtmp = properties
	mbegstring = SUBSTR(mtmp,1,(mpos-1))
	mmidstring = mfind+mreplacewith

	mtmp = SUBSTR(mtmp,mpos+1)

	mchr13 = AT(CHR(13),mtmp)
	mendstring = SUBSTR(mtmp,mchr13)
	m.properties = mbegstring+mmidstring+mendstring
ELSE
	m.properties = properties+CHR(13)+CHR(10)+mfind+mreplacewith
ENDIF
REPL properties WITH  m.properties
RETURN

*********************************
It seems to never work.
At first the BackStyle is at default so it is not inside the property sheet.
When I run this code and then open the form it changes the property back to the default.
Is there some way I can do this automated.
Next
Reply
Map
View

Click here to load this message in the networking platform