Main Menu

KB#00853-Setting background color in a main or child window


Setting background color in a main or child window


The following code illustrates the use of the backcolor and clearbg mnemonics, and the clear mnemonic, in setting background colors in windows and child windows. The documentation on 'backcolor' implies that this should work. 


rem test colors in a child window 


        title$="Test Window" 


        print (sysgui)'WINDOW'(x,y,w,h,title$,flags$) 
        print (sysgui)'child'(101,x+10,y+10,w-200,h-200,$$,$$,1) 

        print (sysgui)'context'(0) 
        print (sysgui)'backcolor'(1),'clearbg' 

        print (sysgui)'context'(1) 
        print (sysgui)'clear'(128,128,128) 

        dim event$:tmpl(sysgui) 


        if event.code$="X" then done=true 

until done 


Last Modified: 11/28/2000 Product: Visual PRO/5 Operating System: Windows

BASIS structures five components of their technology into the BBx Generations.

View BASIS LinkedIN Profile Visit our Twitter Feed Check out our Facebook Public Profile Click to View the BASIS youTube channel