176:
How can I control the height of the control, so no scroll is required to view all items

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Font():Size := 6
		oExContextMenu:MenuAppearance := 0/*exMenuNormal*/
		oItems := oExContextMenu:Items()
			DevOut( Transform(oItems:VisibleItemsCount(),"") )
			oItems:VisibleItemsCount := 255
			oItems:ToString := "1,2,3,4,5,6,7,8,9,10,11,12,13"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
175:
How do I specify the control's height (method 3)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item 1"):ItemHeight := 24
			oItems:Add("Item 2"):ItemHeight := 24
			oItems:Add("Item 3"):ItemHeight := 24
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
174:
How do I specify the control's height (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item 1"):Padding := "0,4,0,4"
			oItems:Add("Item 2"):Padding := "0,4,0,4"
			oItems:Add("Item 3"):Padding := "0,4,0,4"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
173:
How do I specify the control's height (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Font():Size := 12
		oItems := oExContextMenu:Items()
			oItems:Add("Item 1")
			oItems:Add("Item 2")
			oItems:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
172:
How can I change the visual appearance of the progress bar

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oExContextMenu:SetProperty("Background",260/*0x104+*/,0x1000000)
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Progress")
				oitem:AllowEdit := 4/*exItemEditProgress*/
				oitem:EditWidth := -128
				oitem:EditValue := 25
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
171:
How can I change the progress's color

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SetProperty("Background",260/*0x104+*/,AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Progress")
				oitem:AllowEdit := 4/*exItemEditProgress*/
				oitem:EditWidth := -128
				oitem:EditValue := 25
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
170:
I am using the Item.Visible property on False to hide the item, but the editor is still visible

PROCEDURE OnCheckItem(oExContextMenu,Itm)
	LOCAL oitem
	oitem := oExContextMenu:Items:item(1000)
		oitem:Visible := .T.
		oitem:AllowEdit := 260/*exItemEditReadOnly+exItemEditProgress*/
	oExContextMenu:Select()
RETURN

PROCEDURE OnUncheckItem(oExContextMenu,Itm)
	LOCAL oitem
	oitem := oExContextMenu:Items:item(1000)
		oitem:Visible := .F.
		oitem:AllowEdit := 0/*exItemDisableEdit*/
	oExContextMenu:Select()
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:CheckItem := {|Itm| OnCheckItem(oExContextMenu,Itm)} /*Occurs when the user checks the item.*/
		oExContextMenu:UncheckItem := {|Itm| OnUncheckItem(oExContextMenu,Itm)} /*Occurs when the user unchecks the item.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oItems1 := oitem:Items()
					oItems1:Add("Visible")
					oitem1 := oItems1:Add("")
						oitem1:Check := .T.
						oitem1:Checked := .T.
					oitem2 := oItems1:Add("Item 2",,1000)
						oitem2:ItemHeight := 18
						oitem2:Caption := "Percent"
						oitem2:AllowEdit := 260/*exItemEditReadOnly+exItemEditProgress*/
						oitem2:EditValue := 50
						oitem2:Visible := .T.
					oItems1:Add("Visible")
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
169:
How can I change the color of a disabled item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Disabled",2,0)
				oitem:SetProperty("ForeColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
				oitem:Items():Add("")
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
			oItems:Add("Disabled"):Enabled := .F.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
168:
Microsoft Windows 8.1 - Ribbon Like

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oAppearance
	LOCAL oitem,oitem1,oitem10,oitem11,oitem12,oitem13,oitem14,oitem15,oitem16,oitem2,oitem3,oitem4,oitem5,oitem6,oitem7,oitem8,oitem9,var_item,var_item1,var_item2,var_item3,var_item4
	LOCAL oItems,oItems1,oItems10,oItems11,oItems12,oItems13,oItems2,oItems3,oItems4,oItems5,oItems6,oItems7,oItems8,oItems9

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:MenuAppearance := 0/*exMenuNormal*/
		oItems := oExContextMenu:Items()
			oItems:ToString := "[id=0][group=0x03](),[id=-20][bg=0x01000000][group=0x03][itemspad=4,4,4,4]([id=9000])"
			oItems1 := oItems:item(0):Items()
				oItems1:Add("",0,0):Padding := "8,0,0,0"
				var_item3 := oItems1:Add("New Page")
					var_item3:ToString := "[id=0][typ=2][chk=1][spchk=-1][show=1][grp=10][bghot=0x12000000][bgsel=0x11000000][bgselhot=0x14000000][group=0x03][tab=9000][pad=4,0,4,0][popupoffset=-4,-1]([id=0][group=0x03])"
					var_item3:ID := 200
					var_item3:Caption := "Page1"
					var_item := var_item3:Items:Add("New Group")
						var_item:ToString := "[id=0][group=0x03][itemspad=4,4,4,18][itemsbg=0x02000000][itemsbghot=0x04000000]()"
						var_item:Caption := "<b><font ;14>A"
						oItems2 := var_item:Items()
							oItems2:BackgroundExt := "bottom[16,text=`<fgcolor A0A0A0><font ;8>Horizontal`,align=0x11]"
							oitem := oItems2:Add("",2)
								oitem:GroupPopup := 17/*exGroupPopupEqualWidth+exGroupPopup*/
								oitem:Caption := ""
								oItems3 := oitem:Items()
									oitem1 := oItems3:Add("R1")
										oitem1:RadioGroup := 100
										oitem1:Radio := .T.
										oitem1:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
										oitem1:Checked := .F.
									oitem2 := oItems3:Add("R2")
										oitem2:RadioGroup := 100
										oitem2:Radio := .T.
										oitem2:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
										oitem2:Checked := .T.
									oitem3 := oItems3:Add("R3")
										oitem3:RadioGroup := 100
										oitem3:Radio := .T.
										oitem3:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
										oitem3:Checked := .F.
					var_item1 := var_item3:Items:Add("New Group")
						var_item1:ToString := "[id=0][group=0x03][itemspad=4,4,4,18][itemsbg=0x02000000][itemsbghot=0x04000000]()"
						var_item1:Caption := "<b><font ;14>B"
						oItems4 := var_item1:Items()
							oItems4:BackgroundExt := "bottom[16,text=`<fgcolor A0A0A0><font ;8>Vertical`,align=0x11]"
							oitem4 := oItems4:Add("",2)
								oitem4:GroupPopup := 289/*exGroupPopupVertical+exGroupPopupEqualHeight+exGroupPopup*/
								oitem4:Caption := ""
								oItems5 := oitem4:Items()
									oitem5 := oItems5:Add("C1")
										oitem5:Check := .T.
										oitem5:Checked := .T.
									oitem6 := oItems5:Add("C2")
										oitem6:Check := .T.
										oitem6:Checked := .F.
									oitem7 := oItems5:Add("C3")
										oitem7:Check := .T.
										oitem7:Checked := .T.
					var_item3:Items():Add("",0,0):Padding := "4,0,0,0"
					var_item2 := var_item3:Items:Add("New Group")
						var_item2:ToString := "[id=0][group=0x03][itemspad=4,4,4,18][itemsbg=0x02000000][itemsbghot=0x04000000]()"
						var_item2:Caption := ""
						oItems6 := var_item2:Items()
							oItems6:BackgroundExt := "bottom[16,text=`<fgcolor A0A0A0><font ;8>Mixt`,align=0x11]"
							oitem8 := oItems6:Add("",0)
								oitem8:AllowEdit := 1027/*exItemEditVertical+exItemEditSlider*/
								oitem8:ItemHeight := 76
								oitem8:EditBorder := 0/*exEditBorderNone*/
								oitem8:EditValue := 25
							oitem9 := oItems6:Add("",2)
								oitem9:GroupPopup := 259/*exGroupPopupVertical+exNoGroupPopupFrame+exGroupPopup*/
								oitem9:Caption := ""
								oItems7 := oitem9:Items()
									oitem10 := oItems7:Add("",2)
										oitem10:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
										oItems8 := oitem10:Items()
											oitem11 := oItems8:Add("Button1",2)
												oitem11:ShowAsButton := 275/*exShowAsSelectButtonBottom+exShowAsButtonAutoSize*/
												oItems9 := oitem11:Items()
													oItems9:Add("Item 1")
													oItems9:Add("Item 2")
													oItems9:Add("Item 3")
											oItems8:Add("",0,0):Padding := "4,0,0,0"
											oitem12 := oItems8:Add("Button2",2)
												oitem12:ShowAsButton := 275/*exShowAsSelectButtonBottom+exShowAsButtonAutoSize*/
												oItems10 := oitem12:Items()
													oItems10:Add("Item 4")
													oItems10:Add("Item 5")
													oItems10:Add("Item 6")
									oitem13 := oItems7:Add("Popup",2)
										oitem13:Alignment := 1/*exCenter*/
										oItems11 := oitem13:Items()
											oItems11:Add("Item 7"):Check := .T.
											oItems11:Add("Item 8")
											oItems12 := oItems11:Add("Item 9",2):Items()
												oItems12:Add("Item 10")
												oItems12:Add("Item 11")
												oItems12:Add("Item 12")
				var_item4 := oItems1:Add("New Page")
					var_item4:ToString := "[id=0][typ=2][chk=0][spchk=-1][show=1][grp=10][bghot=0x12000000][bgsel=0x11000000][bgselhot=0x14000000][group=0x03][tab=9000][pad=4,0,4,0][popupoffset=-4,-1]([id=0][group=0x03])"
					var_item4:ID := 300
					var_item4:Caption := "Page2"
					oItems13 := var_item4:Items()
						oitem14 := oItems13:Add("S1")
							oitem14:ItemHeight := 88
							oitem14:AllowEdit := 1540/*exItemEditVertical+exItemEditSpin+exItemEditProgress*/
							oitem14:EditValue := 25
						oitem15 := oItems13:Add("S2")
							oitem15:ItemHeight := 88
							oitem15:AllowEdit := 1540/*exItemEditVertical+exItemEditSpin+exItemEditProgress*/
							oitem15:EditValue := 50
						oitem16 := oItems13:Add("S3")
							oitem16:ItemHeight := 88
							oitem16:AllowEdit := 1540/*exItemEditVertical+exItemEditSpin+exItemEditProgress*/
							oitem16:EditValue := 75
				oItems1:Add("",0,0):Padding := "8,0,0,0"
		oAppearance := oExContextMenu:VisualAppearance()
			oAppearance:Add(1,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSFlat-Ribbon/msfr_background.ebn")
			oAppearance:Add(2,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSFlat-Ribbon/msfr_groupt.ebn")
			oAppearance:Add(12,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSFlat-Ribbon/msfr_hot.ebn")
			oAppearance:Add(14,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSFlat-Ribbon/msfr_select.ebn")
			oAppearance:Add(17,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSFlat-Ribbon/msfr_tab.ebn")
			oAppearance:Add(18,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSFlat-Ribbon/msfr_tabhot.ebn")
			oAppearance:Add(32,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSFlat-Ribbon/msfr_check0.ebn")
			oAppearance:Add(33,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSFlat-Ribbon/msfr_check1.ebn")
			oAppearance:Add(34,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSFlat-Ribbon/msfr_buttonu.ebn")
			oAppearance:Add(35,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSFlat-Ribbon/msfr_buttond.ebn")
		oExContextMenu:Appearance := 16777216/*0x1000000+*/
		oExContextMenu:SetProperty("Background",64/*exToolTipAppearance*/,oExContextMenu:Appearance())
		oExContextMenu:SetProperty("SelBackColor",0xe000000)
		oExContextMenu:SetProperty("Background",110/*exMenuHotBackColor*/,0xc000000)
		oExContextMenu:SetProperty("Background",112/*exMenuSelHotBackColor*/,0x23000000)
		oExContextMenu:SetProperty("Background",2/*0x2+*/,0x22000000)
		oExContextMenu:SetProperty("Background",3/*0x3+*/,0x23000000)
		oExContextMenu:SetProperty("Background",70/*exCheckBoxState0*/,0x20000000)
		oExContextMenu:SetProperty("Background",71/*exCheckBoxState1*/,0x21000000)
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
167:
Microsoft Paint - Ribbon Like

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oAppearance
	LOCAL oitem,oitem1,oitem10,oitem11,oitem12,oitem13,oitem14,oitem15,oitem16,oitem2,oitem3,oitem4,oitem5,oitem6,oitem7,oitem8,oitem9,var_item,var_item1,var_item2,var_item3,var_item4
	LOCAL oItems,oItems1,oItems10,oItems11,oItems12,oItems13,oItems2,oItems3,oItems4,oItems5,oItems6,oItems7,oItems8,oItems9

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:MenuAppearance := 0/*exMenuNormal*/
		oItems := oExContextMenu:Items()
			oItems:ToString := "[id=0][group=0x03](),[id=-20][bg=0x01000000][group=0x03][itemspad=4,4,4,4]([id=9000])"
			oItems1 := oItems:item(0):Items()
				oItems1:Add("",0,0):Padding := "8,0,0,0"
				var_item3 := oItems1:Add("New Page")
					var_item3:ToString := "[id=0][typ=2][chk=1][spchk=-1][show=1][grp=10][bghot=0x12000000][bgsel=0x11000000][bgselhot=0x14000000][group=0x03][tab=9000][pad=4,0,4,0][popupoffset=-4,-1]([id=0][group=0x03])"
					var_item3:ID := 200
					var_item3:Caption := "Page1"
					var_item := var_item3:Items:Add("New Group")
						var_item:ToString := "[id=0][group=0x03][itemspad=4,4,4,18][itemsbg=0x02000000][itemsbghot=0x04000000]()"
						var_item:Caption := "<b><font ;14>A"
						oItems2 := var_item:Items()
							oItems2:BackgroundExt := "bottom[16,text=`<fgcolor A0A0A0><font ;8>Horizontal`,align=0x11]"
							oitem := oItems2:Add("",2)
								oitem:GroupPopup := 17/*exGroupPopupEqualWidth+exGroupPopup*/
								oitem:Caption := ""
								oItems3 := oitem:Items()
									oitem1 := oItems3:Add("R1")
										oitem1:RadioGroup := 100
										oitem1:Radio := .T.
										oitem1:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
										oitem1:Checked := .F.
									oitem2 := oItems3:Add("R2")
										oitem2:RadioGroup := 100
										oitem2:Radio := .T.
										oitem2:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
										oitem2:Checked := .T.
									oitem3 := oItems3:Add("R3")
										oitem3:RadioGroup := 100
										oitem3:Radio := .T.
										oitem3:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
										oitem3:Checked := .F.
					var_item1 := var_item3:Items:Add("New Group")
						var_item1:ToString := "[id=0][group=0x03][itemspad=4,4,4,18][itemsbg=0x02000000][itemsbghot=0x04000000]()"
						var_item1:Caption := "<b><font ;14>B"
						oItems4 := var_item1:Items()
							oItems4:BackgroundExt := "bottom[16,text=`<fgcolor A0A0A0><font ;8>Vertical`,align=0x11]"
							oitem4 := oItems4:Add("",2)
								oitem4:GroupPopup := 289/*exGroupPopupVertical+exGroupPopupEqualHeight+exGroupPopup*/
								oitem4:Caption := ""
								oItems5 := oitem4:Items()
									oitem5 := oItems5:Add("C1")
										oitem5:Check := .T.
										oitem5:Checked := .T.
									oitem6 := oItems5:Add("C2")
										oitem6:Check := .T.
										oitem6:Checked := .F.
									oitem7 := oItems5:Add("C3")
										oitem7:Check := .T.
										oitem7:Checked := .T.
					var_item3:Items():Add("",0,0):Padding := "4,0,0,0"
					var_item2 := var_item3:Items:Add("New Group")
						var_item2:ToString := "[id=0][group=0x03][itemspad=4,4,4,18][itemsbg=0x02000000][itemsbghot=0x04000000]()"
						var_item2:Caption := ""
						oItems6 := var_item2:Items()
							oItems6:BackgroundExt := "bottom[16,text=`<fgcolor A0A0A0><font ;8>Mixt`,align=0x11]"
							oitem8 := oItems6:Add("",0)
								oitem8:AllowEdit := 1027/*exItemEditVertical+exItemEditSlider*/
								oitem8:ItemHeight := 76
								oitem8:EditBorder := 0/*exEditBorderNone*/
								oitem8:EditValue := 25
							oitem9 := oItems6:Add("",2)
								oitem9:GroupPopup := 259/*exGroupPopupVertical+exNoGroupPopupFrame+exGroupPopup*/
								oitem9:Caption := ""
								oItems7 := oitem9:Items()
									oitem10 := oItems7:Add("",2)
										oitem10:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
										oItems8 := oitem10:Items()
											oitem11 := oItems8:Add("Button1",2)
												oitem11:ShowAsButton := 275/*exShowAsSelectButtonBottom+exShowAsButtonAutoSize*/
												oItems9 := oitem11:Items()
													oItems9:Add("Item 1")
													oItems9:Add("Item 2")
													oItems9:Add("Item 3")
											oItems8:Add("",0,0):Padding := "4,0,0,0"
											oitem12 := oItems8:Add("Button2",2)
												oitem12:ShowAsButton := 275/*exShowAsSelectButtonBottom+exShowAsButtonAutoSize*/
												oItems10 := oitem12:Items()
													oItems10:Add("Item 4")
													oItems10:Add("Item 5")
													oItems10:Add("Item 6")
									oitem13 := oItems7:Add("Popup",2)
										oitem13:Alignment := 1/*exCenter*/
										oItems11 := oitem13:Items()
											oItems11:Add("Item 7"):Check := .T.
											oItems11:Add("Item 8")
											oItems12 := oItems11:Add("Item 9",2):Items()
												oItems12:Add("Item 10")
												oItems12:Add("Item 11")
												oItems12:Add("Item 12")
				var_item4 := oItems1:Add("New Page")
					var_item4:ToString := "[id=0][typ=2][chk=0][spchk=-1][show=1][grp=10][bghot=0x12000000][bgsel=0x11000000][bgselhot=0x14000000][group=0x03][tab=9000][pad=4,0,4,0][popupoffset=-4,-1]([id=0][group=0x03])"
					var_item4:ID := 300
					var_item4:Caption := "Page2"
					oItems13 := var_item4:Items()
						oitem14 := oItems13:Add("S1")
							oitem14:ItemHeight := 88
							oitem14:AllowEdit := 1540/*exItemEditVertical+exItemEditSpin+exItemEditProgress*/
							oitem14:EditValue := 25
						oitem15 := oItems13:Add("S2")
							oitem15:ItemHeight := 88
							oitem15:AllowEdit := 1540/*exItemEditVertical+exItemEditSpin+exItemEditProgress*/
							oitem15:EditValue := 50
						oitem16 := oItems13:Add("S3")
							oitem16:ItemHeight := 88
							oitem16:AllowEdit := 1540/*exItemEditVertical+exItemEditSpin+exItemEditProgress*/
							oitem16:EditValue := 75
				oItems1:Add("",0,0):Padding := "8,0,0,0"
		oAppearance := oExContextMenu:VisualAppearance()
			oAppearance:Add(1,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_background.ebn")
			oAppearance:Add(2,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_groupt.ebn")
			oAppearance:Add(3,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_groupo.ebn")
			oAppearance:Add(4,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_grouphot.ebn")
			oAppearance:Add(5,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_frameh.ebn")
			oAppearance:Add(6,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_framehs.ebn")
			oAppearance:Add(7,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_framehi.ebn")
			oAppearance:Add(8,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_framehe.ebn")
			oAppearance:Add(9,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_framevs.ebn")
			oAppearance:Add(10,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_framevi.ebn")
			oAppearance:Add(11,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_frameve.ebn")
			oAppearance:Add(12,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_select.ebn")
			oAppearance:Add(13,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_bordert.ebn")
			oAppearance:Add(14,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_buttond.ebn")
			oAppearance:Add(15,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_buttonu.ebn")
			oAppearance:Add(16,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_tab.ebn")
			oAppearance:Add(17,"CP:16 0 0 0 1")
			oAppearance:Add(18,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_tabhot.ebn")
			oAppearance:Add(19,"C:/Program Files/Exontrol/ExContextMenu/Sample/EBN/MSPaint-Ribbon/mspr_tabselhot.ebn")
			oAppearance:Add(20,"CP:19 0 0 0 1")
		oExContextMenu:LocalAppearance := 6/*ShadowBorder*/
		oExContextMenu:Appearance := 16777216/*0x1000000+*/
		oExContextMenu:SetProperty("ForeColor",AutomationTranslateColor( GraMakeRGBColor  ( { 21,66,139 } )  , .F. ))
		oExContextMenu:SetProperty("SelBackColor",0xe000000)
		oExContextMenu:SetProperty("Background",64/*exToolTipAppearance*/,oExContextMenu:Appearance())
		oExContextMenu:SetProperty("Background",2/*0x2+*/,0xd000000)
		oExContextMenu:SetProperty("Background",105/*exGroupPopupFrameSingle*/,0x5000000)
		oExContextMenu:SetProperty("Background",106/*exGroupPopupFrameHStart*/,0x6000000)
		oExContextMenu:SetProperty("Background",107/*exGroupPopupFrameHIntermediate*/,0x7000000)
		oExContextMenu:SetProperty("Background",108/*exGroupPopupFrameHEnd*/,0x8000000)
		oExContextMenu:SetProperty("Background",116/*exGroupPopupFrameVStart*/,0x9000000)
		oExContextMenu:SetProperty("Background",117/*exGroupPopupFrameVIntermediate*/,0xa000000)
		oExContextMenu:SetProperty("Background",118/*exGroupPopupFrameVEnd*/,0xb000000)
		oExContextMenu:SetProperty("Background",110/*exMenuHotBackColor*/,0xc000000)
		oExContextMenu:SetProperty("Background",112/*exMenuSelHotBackColor*/,0xf000000)
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
166:
Microsoft Office - Ribbon Like

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oAppearance
	LOCAL oitem,oitem1,oitem10,oitem11,oitem12,oitem13,oitem14,oitem15,oitem16,oitem2,oitem3,oitem4,oitem5,oitem6,oitem7,oitem8,oitem9,var_item,var_item1,var_item2,var_item3,var_item4
	LOCAL oItems,oItems1,oItems10,oItems11,oItems12,oItems13,oItems2,oItems3,oItems4,oItems5,oItems6,oItems7,oItems8,oItems9

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:MenuAppearance := 0/*exMenuNormal*/
		oItems := oExContextMenu:Items()
			oItems:ToString := "[id=0][group=0x03](),[id=-20][bg=0x01000000][group=0x03][itemspad=4,4,4,4]([id=9000])"
			oItems1 := oItems:item(0):Items()
				oItems1:Add("",0,0):Padding := "8,0,0,0"
				var_item3 := oItems1:Add("New Page")
					var_item3:ToString := "[id=0][typ=2][chk=1][spchk=-1][show=1][grp=10][bghot=0x12000000][bgsel=0x11000000][bgselhot=0x14000000][group=0x03][tab=9000][pad=4,0,4,0][popupoffset=-4,-1]([id=0][group=0x03])"
					var_item3:ID := 200
					var_item3:Caption := "Page1"
					var_item := var_item3:Items:Add("New Group")
						var_item:ToString := "[id=0][group=0x03][itemspad=4,4,4,18][itemsbg=0x02000000][itemsbghot=0x04000000]()"
						var_item:Caption := "<b><font ;14>A"
						oItems2 := var_item:Items()
							oItems2:BackgroundExt := "bottom[16,text=`<fgcolor A0A0A0><font ;8>Horizontal`,align=0x11]"
							oitem := oItems2:Add("",2)
								oitem:GroupPopup := 17/*exGroupPopupEqualWidth+exGroupPopup*/
								oitem:Caption := ""
								oItems3 := oitem:Items()
									oitem1 := oItems3:Add("R1")
										oitem1:RadioGroup := 100
										oitem1:Radio := .T.
										oitem1:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
										oitem1:Checked := .F.
									oitem2 := oItems3:Add("R2")
										oitem2:RadioGroup := 100
										oitem2:Radio := .T.
										oitem2:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
										oitem2:Checked := .T.
									oitem3 := oItems3:Add("R3")
										oitem3:RadioGroup := 100
										oitem3:Radio := .T.
										oitem3:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
										oitem3:Checked := .F.
					var_item1 := var_item3:Items:Add("New Group")
						var_item1:ToString := "[id=0][group=0x03][itemspad=4,4,4,18][itemsbg=0x02000000][itemsbghot=0x04000000]()"
						var_item1:Caption := "<b><font ;14>B"
						oItems4 := var_item1:Items()
							oItems4:BackgroundExt := "bottom[16,text=`<fgcolor A0A0A0><font ;8>Vertical`,align=0x11]"
							oitem4 := oItems4:Add("",2)
								oitem4:GroupPopup := 289/*exGroupPopupVertical+exGroupPopupEqualHeight+exGroupPopup*/
								oitem4:Caption := ""
								oItems5 := oitem4:Items()
									oitem5 := oItems5:Add("C1")
										oitem5:Check := .T.
										oitem5:Checked := .T.
									oitem6 := oItems5:Add("C2")
										oitem6:Check := .T.
										oitem6:Checked := .F.
									oitem7 := oItems5:Add("C3")
										oitem7:Check := .T.
										oitem7:Checked := .T.
					var_item3:Items():Add("",0,0):Padding := "4,0,0,0"
					var_item2 := var_item3:Items:Add("New Group")
						var_item2:ToString := "[id=0][group=0x03][itemspad=4,4,4,18][itemsbg=0x02000000][itemsbghot=0x04000000]()"
						var_item2:Caption := ""
						oItems6 := var_item2:Items()
							oItems6:BackgroundExt := "bottom[16,text=`<fgcolor A0A0A0><font ;8>Mixt`,align=0x11]"
							oitem8 := oItems6:Add("",0)
								oitem8:AllowEdit := 1027/*exItemEditVertical+exItemEditSlider*/
								oitem8:ItemHeight := 76
								oitem8:EditBorder := 0/*exEditBorderNone*/
								oitem8:EditValue := 25
							oitem9 := oItems6:Add("",2)
								oitem9:GroupPopup := 259/*exGroupPopupVertical+exNoGroupPopupFrame+exGroupPopup*/
								oitem9:Caption := ""
								oItems7 := oitem9:Items()
									oitem10 := oItems7:Add("",2)
										oitem10:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
										oItems8 := oitem10:Items()
											oitem11 := oItems8:Add("Button1",2)
												oitem11:ShowAsButton := 275/*exShowAsSelectButtonBottom+exShowAsButtonAutoSize*/
												oItems9 := oitem11:Items()
													oItems9:Add("Item 1")
													oItems9:Add("Item 2")
													oItems9:Add("Item 3")
											oItems8:Add("",0,0):Padding := "4,0,0,0"
											oitem12 := oItems8:Add("Button2",2)
												oitem12:ShowAsButton := 275/*exShowAsSelectButtonBottom+exShowAsButtonAutoSize*/
												oItems10 := oitem12:Items()
													oItems10:Add("Item 4")
													oItems10:Add("Item 5")
													oItems10:Add("Item 6")
									oitem13 := oItems7:Add("Popup",2)
										oitem13:Alignment := 1/*exCenter*/
										oItems11 := oitem13:Items()
											oItems11:Add("Item 7"):Check := .T.
											oItems11:Add("Item 8")
											oItems12 := oItems11:Add("Item 9",2):Items()
												oItems12:Add("Item 10")
												oItems12:Add("Item 11")
												oItems12:Add("Item 12")
				var_item4 := oItems1:Add("New Page")
					var_item4:ToString := "[id=0][typ=2][chk=0][spchk=-1][show=1][grp=10][bghot=0x12000000][bgsel=0x11000000][bgselhot=0x14000000][group=0x03][tab=9000][pad=4,0,4,0][popupoffset=-4,-1]([id=0][group=0x03])"
					var_item4:ID := 300
					var_item4:Caption := "Page2"
					oItems13 := var_item4:Items()
						oitem14 := oItems13:Add("S1")
							oitem14:ItemHeight := 88
							oitem14:AllowEdit := 1540/*exItemEditVertical+exItemEditSpin+exItemEditProgress*/
							oitem14:EditValue := 25
						oitem15 := oItems13:Add("S2")
							oitem15:ItemHeight := 88
							oitem15:AllowEdit := 1540/*exItemEditVertical+exItemEditSpin+exItemEditProgress*/
							oitem15:EditValue := 50
						oitem16 := oItems13:Add("S3")
							oitem16:ItemHeight := 88
							oitem16:AllowEdit := 1540/*exItemEditVertical+exItemEditSpin+exItemEditProgress*/
							oitem16:EditValue := 75
				oItems1:Add("",0,0):Padding := "8,0,0,0"
		oAppearance := oExContextMenu:VisualAppearance()
			oAppearance:Add(1,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_background.ebn")
			oAppearance:Add(2,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_groupt.ebn")
			oAppearance:Add(3,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_groupo.ebn")
			oAppearance:Add(4,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_grouphot.ebn")
			oAppearance:Add(5,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_frameh.ebn")
			oAppearance:Add(6,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_framehs.ebn")
			oAppearance:Add(7,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_framehi.ebn")
			oAppearance:Add(8,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_framehe.ebn")
			oAppearance:Add(9,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_framevs.ebn")
			oAppearance:Add(10,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_framevi.ebn")
			oAppearance:Add(11,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_frameve.ebn")
			oAppearance:Add(12,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_select.ebn")
			oAppearance:Add(13,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_bordert.ebn")
			oAppearance:Add(14,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_buttond.ebn")
			oAppearance:Add(15,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_buttonu.ebn")
			oAppearance:Add(16,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_tab.ebn")
			oAppearance:Add(17,"CP:16 0 0 0 1")
			oAppearance:Add(18,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_tabhot.ebn")
			oAppearance:Add(19,"C:\Program Files\Exontrol\ExContextMenu\Sample\EBN\MSOffice-Ribbon\msor_tabselhot.ebn")
			oAppearance:Add(20,"CP:19 0 0 0 1")
		oExContextMenu:SetProperty("ForeColor",AutomationTranslateColor( GraMakeRGBColor  ( { 21,66,139 } )  , .F. ))
		oExContextMenu:SetProperty("SelBackColor",0xe000000)
		oExContextMenu:LocalAppearance := 6/*ShadowBorder*/
		oExContextMenu:Appearance := 16777216/*0x1000000+*/
		oExContextMenu:SetProperty("Background",64/*exToolTipAppearance*/,oExContextMenu:Appearance())
		oExContextMenu:SetProperty("Background",2/*0x2+*/,0xd000000)
		oExContextMenu:SetProperty("Background",105/*exGroupPopupFrameSingle*/,0x5000000)
		oExContextMenu:SetProperty("Background",106/*exGroupPopupFrameHStart*/,0x6000000)
		oExContextMenu:SetProperty("Background",107/*exGroupPopupFrameHIntermediate*/,0x7000000)
		oExContextMenu:SetProperty("Background",108/*exGroupPopupFrameHEnd*/,0x8000000)
		oExContextMenu:SetProperty("Background",116/*exGroupPopupFrameVStart*/,0x9000000)
		oExContextMenu:SetProperty("Background",117/*exGroupPopupFrameVIntermediate*/,0xa000000)
		oExContextMenu:SetProperty("Background",118/*exGroupPopupFrameVEnd*/,0xb000000)
		oExContextMenu:SetProperty("Background",110/*exMenuHotBackColor*/,0xc000000)
		oExContextMenu:SetProperty("Background",112/*exMenuSelHotBackColor*/,0xf000000)
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
165:
How I can assign buttons to a tab

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1
	LOCAL oItems,oItems1,oItems2,oItems3

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SetProperty("Background",102/*exMenuSelBorderColor*/,AutomationTranslateColor( GraMakeRGBColor  ( { 240,240,240 } )  , .F. ))
		oItems := oExContextMenu:Items()
			oItems:ToString := "[id=0][group=0x0103][itemspad=4,4,4,4]([id=-10][group=0x03](),[id=0][bg=RGB(240,240,240)][group=0x03][itemspad=4,4,4,4]([id=-100]))"
			oItems1 := oItems:item(-10):Items()
				oItems1:Add("",0,0):Padding := "8,0,0,0"
				oitem := oItems1:Add("New Page")
					oitem:ToString := "[typ=2][chk=1][spchk=-1][show=1][grp=10][bghot=RGB(255,255,255)][bgsel=RGB(240,240,240)][bgselhot=RGB(240,240,240)][height=16][group=0x03][tab=-100][pad=2,0,2,0]([id=50][group=0x03]([]))"
					oitem:Caption := "Page<off -5><font ;5><b>1</b></font></off>"
					oItems2 := oitem:Items()
						oItems2:Add("Button 1"):ShowAsButton := 3/*exShowAsButtonAutoSize+exShowAsButton*/
						oItems2:Add("Button 2"):ShowAsButton := 3/*exShowAsButtonAutoSize+exShowAsButton*/
						oItems2:Add("Button 3"):ShowAsButton := 3/*exShowAsButtonAutoSize+exShowAsButton*/
				oitem1 := oItems1:Add("New Page")
					oitem1:ToString := "[typ=2][chk=0][spchk=-1][show=1][grp=10][bghot=RGB(255,255,255)][bgsel=RGB(240,240,240)][bgselhot=RGB(240,240,240)][height=16][group=0x03][tab=-100][pad=2,0,2,0]([id=50][group=0x03]([]))"
					oitem1:Caption := "Page<off -5><font ;5><b>2</b></font></off>"
					oItems3 := oitem1:Items()
						oItems3:Add("Button 3"):ShowAsButton := 3/*exShowAsButtonAutoSize+exShowAsButton*/
						oItems3:Add("Button 4"):ShowAsButton := 3/*exShowAsButtonAutoSize+exShowAsButton*/
				oItems1:Add("",0,0):Padding := "8,0,0,0"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
164:
How can I hide an item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item 1"):Visible := .F.
			oItems:Add("Item 2")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
163:
How do I get the item giving its caption

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item 1"):ID := 1000
			oItems:Add("Item 2"):ID := 1001
		oExContextMenu:item("Item 1"):Bold := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
162:
How do I get the item giving its identifier

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item 1"):ID := 1000
			oItems:Add("Item 2"):ID := 1001
		oExContextMenu:item(1000):Bold := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
161:
Can I change the cursor where it hovers the item
#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Cursor := "exCross"
		oItems := oExContextMenu:Items()
			oItems:Add("Item 1")
			oItems:Add("Item 2"):Cursor := "exNoDrop"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
160:
I am using radio-buttons, the question is it possible to uncheck the radio-buttons, so no button is pressed in the group

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:AllowToggleRadio := .T.
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Radio 1",,1000)
				oitem:Radio := .T.
				oitem:RadioGroup := 100
			oitem1 := oItems:Add("Radio 2",,1001)
				oitem1:Radio := .T.
				oitem1:RadioGroup := 100
			oitem2 := oItems:Add("Radio 2",,1003)
				oitem2:Radio := .T.
				oitem2:RadioGroup := 100
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
159:
Is it possible to display the item's identifiers

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Debug := .T.
		oItems := oExContextMenu:Items()
			oItems:Add("Item 1"):ID := 10001
			oItems:Add("Item 2"):ID := 10002
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
158:
How do I disable showing the tooltip for all control (method 2)
#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:AllowToolTip := .F.
		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Tooltip := "this is a bit of text to be shown when cursor hovers it"
			oItems:Add("Item"):Tooltip := "this is a bit of text to be shown when cursor hovers it"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
157:
How can I disable the control

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item 1"):Enabled := .F.
			oItems:Add("Item 2"):Enabled := .F.
			oItems:Add("Item 3"):Enabled := .F.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
156:
How can I specify a different border/visual appearance for drop down portion of the select buttons/combobox (ebn)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2
	LOCAL oItems,oItems1,oItems2,oItems3

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oExContextMenu:LocalAppearance := 16777216/*0x1000000+*/
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("Button",2)
						oitem1:ShowAsButton := 275/*exShowAsSelectButtonBottom+exShowAsButtonAutoSize*/
						oItems2 := oitem1:Items()
							oItems2:Add("Item 1")
							oItems2:Add("Item 2")
							oItems2:Add("Item 3")
					oitem2 := oItems1:Add("Button",2)
						oitem2:ShowAsButton := 275/*exShowAsSelectButtonBottom+exShowAsButtonAutoSize*/
						oItems3 := oitem2:Items()
							oItems3:Add("Item 4")
							oItems3:Add("Item 5")
							oItems3:Add("Item 6")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
155:
How can I specify a different border for drop down portion of the select buttons/combobox

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2
	LOCAL oItems,oItems1,oItems2,oItems3

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:LocalAppearance := 6/*ShadowBorder*/
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("Button",2)
						oitem1:ShowAsButton := 275/*exShowAsSelectButtonBottom+exShowAsButtonAutoSize*/
						oItems2 := oitem1:Items()
							oItems2:Add("Item 1")
							oItems2:Add("Item 2")
							oItems2:Add("Item 3")
					oitem2 := oItems1:Add("Button",2)
						oitem2:ShowAsButton := 275/*exShowAsSelectButtonBottom+exShowAsButtonAutoSize*/
						oItems3 := oitem2:Items()
							oItems3:Add("Item 4")
							oItems3:Add("Item 5")
							oItems3:Add("Item 6")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
154:
How can I change the visual appearance for the entire control

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oExContextMenu:Appearance := 16777216/*0x1000000+*/
		oExContextMenu:ShowCheckedAsSelected := -1/*exDisplayItemCheckHighlight*/
		oItems := oExContextMenu:Items()
			oItems:Padding := "4,4,4,4"
			oitem := oItems:Add("Radio 1")
				oitem:Radio := .T.
				oitem:Checked := .T.
			oItems:Add("Radio 2"):Radio := .T.
			oItems:Add("Radio 3"):Radio := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
153:
How can I show a border arround the control

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Appearance := 1/*FlatBorder*/
		oExContextMenu:ShowCheckedAsSelected := -1/*exDisplayItemCheckHighlight*/
		oItems := oExContextMenu:Items()
			oItems:Padding := "4,4,4,4"
			oitem := oItems:Add("Check 1")
				oitem:Checked := .T.
				oitem:Check := .T.
			oitem1 := oItems:Add("Check 2")
				oitem1:Check := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
152:
Is it possible to change the item's background color when check/uncheck the item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:ShowCheckedAsSelected := -1/*exDisplayItemCheckHighlight*/
		oItems := oExContextMenu:Items()
			oItems:Padding := "4,4,4,4"
			oitem := oItems:Add("Check 1")
				oitem:Checked := .T.
				oitem:Check := .T.
			oitem1 := oItems:Add("Check 2")
				oitem1:Check := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
151:
How can I change the colors for hot/hover items

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SetProperty("Background",110/*exMenuHotBackColor*/,AutomationTranslateColor( GraMakeRGBColor  ( { 0,0,1 } )  , .F. ))
		oExContextMenu:SetProperty("Background",111/*exMenuHotForeColor*/,AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
		oExContextMenu:SetProperty("Background",112/*exMenuSelHotBackColor*/,AutomationTranslateColor( GraMakeRGBColor  ( { 128,128,128 } )  , .F. ))
		oExContextMenu:SetProperty("Background",113/*exMenuSelHotForeColor*/,AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
		oExContextMenu:SetProperty("SelBackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 128,128,128 } )  , .F. ))
		oExContextMenu:SetProperty("SelForeColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
		oExContextMenu:SetProperty("Background",102/*exMenuSelBorderColor*/,AutomationTranslateColor( GraMakeRGBColor  ( { 128,128,128 } )  , .F. ))
		oExContextMenu:ShowCheckedAsSelected := -1/*exDisplayItemCheckHighlight*/
		oItems := oExContextMenu:Items()
			oItems:Padding := "4,4,4,4"
			oItems:Add(""):ToString := "[group=3](Item 1,Item 2)"
			oitem := oItems:Add("Check 1")
				oitem:Checked := .T.
				oitem:Check := .T.
			oitem1 := oItems:Add("Check 2")
				oitem1:Check := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
150:
How do I change the visual appearance of the groups (vertical)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oAppearance
	LOCAL oitem,oitem1,oitem2
	LOCAL oItems,oItems1,oItems2,oItems3

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oAppearance := oExContextMenu:VisualAppearance()
			oAppearance:Add(1,"c:\exontrol\images\normal.ebn")
			oAppearance:Add(2,"c:\exontrol\images\pushed.ebn")
			oAppearance:Add(3,"c:\exontrol\images\hot.ebn")
		oExContextMenu:SetProperty("Background",105/*exGroupPopupFrameSingle*/,0x1000000)
		oExContextMenu:SetProperty("Background",116/*exGroupPopupFrameVStart*/,0x1000000)
		oExContextMenu:SetProperty("Background",117/*exGroupPopupFrameVIntermediate*/,0x2000000)
		oExContextMenu:SetProperty("Background",118/*exGroupPopupFrameVEnd*/,0x3000000)
		oExContextMenu:SetProperty("Background",109/*exGroupPopupFrameSolid*/,AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("Vertical",2)
						oitem1:Alignment := 1/*exCenter*/
						oitem1:GroupPopup := 257/*exGroupPopupVertical+exGroupPopup*/
						oItems2 := oitem1:Items()
							oItems2:Add("Item 1")
							oItems2:Add("Item 2")
							oItems2:Add("Item 3")
							oItems2:Add("Item 4")
							oItems2:Add("Item 5")
					oItems1:Add(""):CaptionWidth := 12
					oitem2 := oItems1:Add("Vertical",2)
						oitem2:Alignment := 1/*exCenter*/
						oitem2:GroupPopup := 449/*exGroupPopupVertical+exGroupPopupFrameThickBox+exGroupPopupFrameSolidBox+exGroupPopup*/
						oItems3 := oitem2:Items()
							oItems3:Add("Item 1")
							oItems3:Add("Item 2")
							oItems3:Add("Item 3")
							oItems3:Add("Item 4")
							oItems3:Add("Item 5")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
149:
How do I change the visual appearance of the groups (horizontal)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oAppearance
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oAppearance := oExContextMenu:VisualAppearance()
			oAppearance:Add(1,"c:\exontrol\images\normal.ebn")
			oAppearance:Add(2,"c:\exontrol\images\pushed.ebn")
			oAppearance:Add(3,"c:\exontrol\images\hot.ebn")
		oExContextMenu:SetProperty("Background",105/*exGroupPopupFrameSingle*/,0x1000000)
		oExContextMenu:SetProperty("Background",106/*exGroupPopupFrameHStart*/,0x1000000)
		oExContextMenu:SetProperty("Background",107/*exGroupPopupFrameHIntermediate*/,0x2000000)
		oExContextMenu:SetProperty("Background",108/*exGroupPopupFrameHEnd*/,0x3000000)
		oExContextMenu:SetProperty("Background",109/*exGroupPopupFrameSolid*/,AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Horizontal Group",2)
				oitem:GroupPopup := 1/*exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
					oItems1:Add("Item 4")
					oItems1:Add("Item 5")
			oItems:Add(""):ToString := "Horizontal Group[group=193](Item 1,Item 2,Item 3,Item 4,Item 5)"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
148:
How can I change the visual appearance of the separator item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oExContextMenu:SetProperty("Background",103/*exMenuSeparatorItem*/,0x1000000)
		oItems := oExContextMenu:Items()
			oItems:Add("Item"):CaptionWidth := 128
			oItems:Add("",1)
			oItems:Add("Item"):CaptionWidth := 128
			oItems:Add(""):ToString := "<font ;5>separator[sep]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
147:
How can I change the visual appearance of the flat portion of the drop down of the control

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oExContextMenu:SetProperty("FlatBackColor",0x1000000)
		oExContextMenu:SetProperty("Background",100/*exMenuFlatLineColor*/,oExContextMenu:FlatBackColor())
		oItems := oExContextMenu:Items()
			oItems1 := oItems:Add("Popup",2):Items()
				oItems1:Add("Item 1"):Check := .T.
				oItems1:Add("Item 2"):Check := .T.
				oItems1:Add("Item 3"):Check := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
146:
How can I change the visual appearance of the radio-buttons to be displayed in the context menu (ebn)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oAppearance
	LOCAL oitem,oitem1,oitem2,oitem3
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oAppearance := oExContextMenu:VisualAppearance()
			oAppearance:Add(1,"c:\exontrol\images\normal.ebn")
			oAppearance:Add(2,"c:\exontrol\images\pushed.ebn")
		oExContextMenu:SetProperty("Background",73/*exRadioButtonState0*/,0x1000000)
		oExContextMenu:SetProperty("Background",74/*exRadioButtonState1*/,0x2000000)
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 1/*exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("Radio 1",,1000)
						oitem1:Radio := .T.
						oitem1:RadioGroup := 100
					oitem2 := oItems1:Add("Radio 2",,1001)
						oitem2:Radio := .T.
						oitem2:RadioGroup := 100
					oitem3 := oItems1:Add("Radio 2",,1003)
						oitem3:Radio := .T.
						oitem3:RadioGroup := 100
					oItems1:item(1000):Checked := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
145:
How can I change the visual appearance of the check-boxes to be displayed in the context menu (ebn)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oAppearance
	LOCAL oitem,oitem1
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oAppearance := oExContextMenu:VisualAppearance()
			oAppearance:Add(1,"c:\exontrol\images\normal.ebn")
			oAppearance:Add(2,"c:\exontrol\images\pushed.ebn")
		oExContextMenu:SetProperty("Background",70/*exCheckBoxState0*/,0x1000000)
		oExContextMenu:SetProperty("Background",71/*exCheckBoxState1*/,0x2000000)
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("Check 1")
						oitem1:Check := .T.
						oitem1:Checked := .T.
					oItems1:Add("Check 2"):Check := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
144:
How can I change the visual appearance of the tooltips to be displayed in the context menu (ebn)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oAppearance
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oAppearance := oExContextMenu:VisualAppearance()
			oAppearance:Add(1,"c:\exontrol\images\normal.ebn")
			oAppearance:Add(2,"c:\exontrol\images\pushed.ebn")
		oExContextMenu:ToolTipDelay := 1
		oExContextMenu:SetProperty("Background",64/*exToolTipAppearance*/,0x1000000)
		oExContextMenu:SetProperty("Background",66/*exToolTipForeColor*/,AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Tooltip := "this is a bit of text to be shown when cursor hovers it"
			oItems:Add("Item"):Tooltip := "this is a bit of text to be shown when cursor hovers it"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
143:
Is it possible to change the visual appearance of the buttons to be displayed in the context menu (ebn)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oAppearance
	LOCAL oitem,oitem1,oitem2,oitem3
	LOCAL oItems,oItems1,oItems2

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oAppearance := oExContextMenu:VisualAppearance()
			oAppearance:Add(1,"c:\exontrol\images\normal.ebn")
			oAppearance:Add(2,"c:\exontrol\images\pushed.ebn")
		oExContextMenu:SetProperty("Background",2/*0x2+*/,0x1000000)
		oExContextMenu:SetProperty("Background",3/*0x3+*/,0x2000000)
		oExContextMenu:SetProperty("Background",114/*exMenuSeparatorSelectButton*/,AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
		oExContextMenu:SetProperty("Background",115/*exMenuSeparatorSelectButtonBottom*/,AutomationTranslateColor( GraMakeRGBColor  ( { 0,0,255 } )  , .F. ))
		oItems := oExContextMenu:Items()
			oItems:Padding := "4,4,4,4"
			oItems:Add("Button"):ShowAsButton := 3/*exShowAsButtonAutoSize+exShowAsButton*/
			oitem := oItems:Add("")
				oitem:Enabled := .F.
				oitem:ItemHeight := 4
			oitem1 := oItems:Add("Button",2)
				oitem1:ShowAsButton := 275/*exShowAsSelectButtonBottom+exShowAsButtonAutoSize*/
				oItems1 := oitem1:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oitem2 := oItems:Add("")
				oitem2:Enabled := .F.
				oitem2:ItemHeight := 4
			oitem3 := oItems:Add("Button",2)
				oitem3:ShowAsButton := 19/*exShowAsSelectButton+exShowAsButtonAutoSize*/
				oItems2 := oitem3:Items()
					oItems2:Add("Item 1")
					oItems2:Add("Item 2")
					oItems2:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
142:
I've seen that the width of the tooltip is variable. Can I make it larger

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:ToolTipWidth := 328
		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Tooltip := "this is a bit of text to be shown when cursor hovers it"
			oItems:Add("Item"):Tooltip := "this is a bit of text to be shown when cursor hovers it"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
141:
How do I disable showing the tooltip for all control (method 1)
#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:ToolTipDelay := 0
		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Tooltip := "this is a bit of text to be shown when cursor hovers it"
			oItems:Add("Item"):Tooltip := "this is a bit of text to be shown when cursor hovers it"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
140:
How do I let the tooltip being displayed longer

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:ToolTipPopDelay := 10000
		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Tooltip := "this is a bit of text to be shown when cursor hovers it"
			oItems:Add("Item"):Tooltip := "this is a bit of text to be shown when cursor hovers it"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
139:
How do I show the tooltip quicker

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:ToolTipDelay := 1
		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Tooltip := "this is a bit of text to be shown when cursor hovers it"
			oItems:Add("Item"):Tooltip := "this is a bit of text to be shown when cursor hovers it"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
138:
How can I get the version of the control I am running
#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		DevOut( oExContextMenu:Version() )

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
137:
How can I align the picture on the control's background
#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Picture := oExContextMenu:ExecuteTemplate("loadpicture(`c:\exontrol\images\card.png`)")
		oExContextMenu:PictureDisplay := 2/*UpperRight*/
		oItems := oExContextMenu:Items()
			oItems:Add("Item")
			oItems:Add("Item")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
136:
Is it possible to place a picture on the control's background
#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Picture := oExContextMenu:ExecuteTemplate("loadpicture(`c:\exontrol\images\card.png`)")
		oItems := oExContextMenu:Items()
			oItems:Add("Item")
			oItems:Add("Item")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
135:
How can I display the item using a different font/size

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add(""):Caption := "<font ;14>This is a bit of text"
			oItems:Add("<font ;6>This is a bit of text")
			oItems:Add(""):Caption := "<font Times New Roman;22>This is a bit of text</font>. Default"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
134:
How can I use the Event event, available for /COM version

PROCEDURE OnEvent(oExContextMenu,EventID)
	DevOut( "Event" )
	DevOut( Transform(oExContextMenu:EventParam(-2),"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Event := {|EventID| OnEvent(oExContextMenu,EventID)} /*Notifies the application once the control fires an event.*/

		oItems := oExContextMenu:Items()
			oItems:Add("Check"):Check := .T.
			oitem := oItems:Add("Slider")
				oitem:AllowEdit := 3/*exItemEditSlider*/
				oitem:EditWidth := 128
				oitem:EditBorder := 0/*exEditBorderNone*/
				oitem:EditValue := 25
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
133:
Is it possible to get notified once the user edits the field, or change the slider value

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( "EditChange event on Itm object" )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Item")
				oitem:AllowEdit := 3/*exItemEditSlider*/
				oitem:EditWidth := 128
				oitem:EditBorder := 0/*exEditBorderNone*/
				oitem:EditValue := 25
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
132:
How do I get notified once I uncheck an item
PROCEDURE OnUncheckItem(oExContextMenu,Itm)
	DevOut( "UncheckItem event on Itm object" )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:UncheckItem := {|Itm| OnUncheckItem(oExContextMenu,Itm)} /*Occurs when the user unchecks the item.*/

		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Check := .T.
			oItems:Add("Item"):Check := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
131:
How do I get notified once I check an item
PROCEDURE OnCheckItem(oExContextMenu,Itm)
	DevOut( "CheckItem event on Itm object" )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:CheckItem := {|Itm| OnCheckItem(oExContextMenu,Itm)} /*Occurs when the user checks the item.*/

		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Check := .T.
			oItems:Add("Item"):Check := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
130:
How do I get notified once I click/select an item
PROCEDURE OnSelectItem(oExContextMenu,Itm)
	DevOut( "SelectItem event on Itm object" )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SelectItem := {|Itm| OnSelectItem(oExContextMenu,Itm)} /*Occurs when the user selects the item.*/

		oItems := oExContextMenu:Items()
			oItems:Add("Item")
			oItems:Add("Item")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
129:
Does your control support padding for items

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:MenuAppearance := 0/*exMenuNormal*/
		oItems := oExContextMenu:Items()
			oItems:Padding := "2,12,2,2"
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oItems:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
			oItems:BackgroundExt := "root[pattern=0x000,frame=RGB(128,128,128)](top[2],top[10,text=`<font ;6><fgcolor 808080> group </font></fgcolor>`,align=0x11])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
128:
How can I change the visual appearance for items, when cursor hovers it (hot,EBN)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:SetProperty("HotBackColor",0x1000000)
					oItems1:Padding := "4,8,4,8"
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oItems:Add(""):ToString := "[group=0x03][itemspad=4,8,4,8][itemsbghot=0x1000000](Item 1,Item 2,Item 3)"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
127:
How can I change the background color for items, when cursor hovers it (hot)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:SetProperty("HotBackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
					oItems1:Padding := "0,8,0,8"
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oItems:Add(""):ToString := "[group=0x03][itemspad=0,8,0,8][itemsbghot=RGB(255,0,0)](Item 1,Item 2,Item 3)"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
126:
How can I change the visual appearance for items (EBN)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:SetProperty("BackColor",0x1000000)
					oItems1:Padding := "4,8,4,8"
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oItems:Add(""):ToString := "[group=0x03][itemspad=4,8,4,8][itemsbg=0x1000000](Item 1,Item 2,Item 3)"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
125:
How can I change the background color for items

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
					oItems1:Padding := "0,8,0,8"
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oItems:Add(""):ToString := "[group=0x03][itemspad=0,8,0,8][itemsbg=RGB(255,0,0)](Item 1,Item 2,Item 3)"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
124:
How do I hide the left gray portion to be shown on the drop down menu/popup (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:FlatImageWidth := 0
		oItems := oExContextMenu:Items()
			oItems1 := oItems:Add("Popup",2):Items()
				oItems1:Add("Item 1")
				oItems1:Add("Item 2")
				oItems1:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
123:
How do I hide the left gray portion to be shown on the drop down menu/popup (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:MenuAppearance := 0/*exMenuNormal*/
		oItems := oExContextMenu:Items()
			oItems1 := oItems:Add("Popup",2):Items()
				oItems1:Add("Item 1")
				oItems1:Add("Item 2")
				oItems1:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
122:
How can I arrange the drop down item from left to right, rather than top to bottom

PROCEDURE OnSelectItem(oExContextMenu,Itm)
	DevOut( "Clicked" )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1
	LOCAL oItems,oItems1,oItems2

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SelectItem := {|Itm| OnSelectItem(oExContextMenu,Itm)} /*Occurs when the user selects the item.*/

		oExContextMenu:MenuAppearance := 0/*exMenuNormal*/
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Button",2)
				oitem:ShowAsButton := 275/*exShowAsSelectButtonBottom+exShowAsButtonAutoSize*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("",2)
						oitem1:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
						oItems2 := oitem1:Items()
							oItems2:Add("Item 1")
							oItems2:Add("Item 2")
							oItems2:Add("Item 3")
			oItems:Add(""):ToString := "Button[button=0x0113][popupapp=6]([group=0x03](Item 1,Item 2,Item 3))"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
121:
How can I add a drop down button / combobox (method 2)

PROCEDURE OnSelectItem(oExContextMenu,Itm)
	DevOut( "Clicked" )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SelectItem := {|Itm| OnSelectItem(oExContextMenu,Itm)} /*Occurs when the user selects the item.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Button",2)
				oitem:ShowAsButton := 275/*exShowAsSelectButtonBottom+exShowAsButtonAutoSize*/
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oItems:Add(""):ToString := "Button[button=275][popupapp=6](Item 1[id=20],Item 2[id=30],Item 3[id=40])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
120:
How can I add a drop down button / combobox (method 1)

PROCEDURE OnSelectItem(oExContextMenu,Itm)
	DevOut( "Clicked" )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SelectItem := {|Itm| OnSelectItem(oExContextMenu,Itm)} /*Occurs when the user selects the item.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Button",2)
				oitem:ShowAsButton := 19/*exShowAsSelectButton+exShowAsButtonAutoSize*/
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oItems:Add(""):ToString := "Button[button=0x13][popupapp=6](Item 1[id=20],Item 2[id=30],Item 3[id=40])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
119:
I am using exShowAsSelectButton/exShowAsSelectButtonBottom but none of them works. What could be wrong

PROCEDURE OnSelectItem(oExContextMenu,Itm)
	DevOut( "Clicked" )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SelectItem := {|Itm| OnSelectItem(oExContextMenu,Itm)} /*Occurs when the user selects the item.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Button",2)
				oitem:ShowAsButton := 19/*exShowAsSelectButton+exShowAsButtonAutoSize*/
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
118:
How can I add a button (push button)

PROCEDURE OnSelectItem(oExContextMenu,Itm)
	DevOut( "Clicked" )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SelectItem := {|Itm| OnSelectItem(oExContextMenu,Itm)} /*Occurs when the user selects the item.*/

		oItems := oExContextMenu:Items()
			oItems:Add("Button"):ShowAsButton := 3/*exShowAsButtonAutoSize+exShowAsButton*/
			oItems:Add(""):ToString := "Button[button=0x03]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
117:
How can I display grouping items with no frame arround

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Horizontal Group",2)
				oitem:GroupPopup := 243/*exGroupPopupFrameThickBox+exGroupPopupFrameSolidBox+exGroupPopupEqualHeight+exGroupPopupEqualWidth+exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:Add("A"):Alignment := 1/*exCenter*/
					oItems1:Add("BC"):Alignment := 1/*exCenter*/
					oItems1:Add("D"):Alignment := 1/*exCenter*/
			oItems:Add(""):ToString := "Horizontal Group[group=243](A[id=20][align=1],BC[id=30][align=1],D[id=40][align=1])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
116:
How can I display grouping items of the same size/width/height

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Horizontal Group",2)
				oitem:GroupPopup := 241/*exGroupPopupFrameThickBox+exGroupPopupFrameSolidBox+exGroupPopupEqualHeight+exGroupPopupEqualWidth+exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:Add("A"):Alignment := 1/*exCenter*/
					oItems1:Add("BC"):Alignment := 1/*exCenter*/
					oItems1:Add("D"):Alignment := 1/*exCenter*/
			oItems:Add(""):ToString := "Horizontal Group[group=0xF1](A[id=20][align=1],BC[id=30][align=1],D[id=40][align=1])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
115:
Is it possible to display a ticker frame arround grouping items

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Horizontal Group",2)
				oitem:GroupPopup := 193/*exGroupPopupFrameThickBox+exGroupPopupFrameSolidBox+exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oItems:Add(""):ToString := "Horizontal Group[group=193](Item 1[id=20],Item 2[id=30],Item 3[id=40])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
114:
How do I display items horizontally arranged

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Horizontal Group",2)
				oitem:GroupPopup := 1/*exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oItems:Add(""):ToString := "Horizontal Group[group=0x01](Item 1[id=20],Item 2[id=30],Item 3[id=40])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
113:
Is it possible to expand an item when it is clicked (tree,group,vertical)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Expand",2)
				oitem:GroupPopup := 259/*exGroupPopupVertical+exNoGroupPopupFrame+exGroupPopup*/
				oitem:Check := .T.
				oitem:ShowPopupOnChecked := .T.
				oItems1 := oitem:Items()
					oItems1:Padding := "22,0,0,0"
					oItems1:Add("Radio 1"):Radio := .T.
					oItems1:Add("Radio 2"):Radio := .T.
					oitem1 := oItems1:Add("Radio 3")
						oitem1:Radio := .T.
						oitem1:Checked := .T.
				oitem:Checked := .T.
			oItems:Add(""):ToString := "Expand[typ=1][chk=1][spchk=-1][group=0x0103][itemspad=22,0,0,0](Radio 1[id=20][typ=2],Radio 2[id=30][typ=2],Radio 3[id=40][typ=2][chk=1])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
112:
Is it possible to expand an item when it is clicked (tree,group,vertical)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Expand",2)
				oitem:GroupPopup := 259/*exGroupPopupVertical+exNoGroupPopupFrame+exGroupPopup*/
				oitem:Check := .T.
				oitem:ShowPopupOnChecked := .T.
				oItems1 := oitem:Items()
					oItems1:Padding := "22,0,0,0"
					oItems1:Add("Radio 1"):Radio := .T.
					oItems1:Add("Radio 2"):Radio := .T.
					oitem1 := oItems1:Add("Radio 3")
						oitem1:Radio := .T.
						oitem1:Checked := .T.
				oitem:Checked := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
111:
Is it possible to expand an item when it is clicked (group)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Expand",2)
				oitem:GroupPopup := 1/*exGroupPopup*/
				oitem:ItemHeight := 24
				oitem:Check := .T.
				oitem:ShowPopupOnChecked := .T.
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
110:
Is it possible to extend an item when it is clicked

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Expand",2)
				oitem:Check := .T.
				oitem:ShowPopupOnChecked := .T.
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
109:
Does your control implement padding for item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 250,250,250 } )  , .F. ))
			oItems:Add("Item"):Padding := "4,4,4,4"
			oItems:Add(""):ToString := "Item[pad=4,4,4,4]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
108:
How can I add an empty item for a horizontal group

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oitem1 := oItems1:Add("",2)
						oitem1:GroupPopup := 5/*exGroupPopupCenter+exGroupPopup*/
						oitem1:ItemHeight := 12
						oitem2 := oitem1:Items():Add("")
							oitem2:Enabled := .F.
							oitem2:ItemHeight := 8
							oitem2:CaptionWidth := 8
					oItems1:Add("Item 2")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
107:
How can I add an empty/separator item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item")
			oitem := oItems:Add("")
				oitem:Enabled := .F.
				oitem:ItemHeight := 2
				oitem:CaptionWidth := 8
				oitem:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 240,240,240 } )  , .F. ))
			oItems:Add("Item")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
106:
How can I add an empty/frame item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item 1")
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 5/*exGroupPopupCenter+exGroupPopup*/
				oitem:ItemHeight := 12
				oitem1 := oitem:Items():Add("")
					oitem1:Enabled := .F.
					oitem1:ItemHeight := 8
					oitem1:CaptionWidth := 8
			oItems:Add("Item 2")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
105:
How can I specify the height of the item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 250,250,250 } )  , .F. ))
			oItems:Add("Item"):ItemHeight := 64
			oItems:Add(""):ToString := "Item[height=64]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
104:
How can I specify the width of the item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 250,250,250 } )  , .F. ))
			oItems:Add("Item"):CaptionWidth := 128
			oItems:Add(""):ToString := "Item[captionwidth=128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
103:
How do I align the item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 250,250,250 } )  , .F. ))
			oItems:Add("Item")
			oitem := oItems:Add("Item")
				oitem:Alignment := 1/*exCenter*/
				oitem:CaptionWidth := 128
			oitem1 := oItems:Add("Item")
				oitem1:Alignment := 2/*exRight*/
				oitem1:CaptionWidth := 128
			oItems:Add(""):ToString := "Item[align=1]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
102:
How can I underline the item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Underline := .T.
			oItems:Add("<u>Item</u>")
			oItems:Add(""):ToString := "Item[und]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
101:
How can I show the item as strikeout

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Strikeout := .T.
			oItems:Add("<s>Item</s>")
			oItems:Add(""):ToString := "Item[stk]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
100:
How can I show the item in italics

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Italic := .T.
			oItems:Add("<i>Item</i>")
			oItems:Add(""):ToString := "Item[itl]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
99:
How can I show the item in bold

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Bold := .T.
			oItems:Add("<b>Item</b>")
			oItems:Add(""):ToString := "Item[bld]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
98:
How can I show the item as disabled but still be able to select or use it

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item"):ShowAsDisabled := .T.
			oItems:Add(""):ToString := "Item[showdis=1]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
97:
How can I enable or disable an item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Enabled := .F.
			oItems:Add(""):ToString := "Item[dis]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
96:
How can I add a separator item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item"):CaptionWidth := 128
			oItems:Add("<font ;6>separator",1)
			oItems:Add("Item"):CaptionWidth := 128
			oItems:Add(""):ToString := "<font ;6>separator[sep]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
95:
How can I change the item's foreground color

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item"):SetProperty("ForeColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
			oItems:Add("<fgcolor FF0000>Item")
			oItems:Add(""):ToString := "Item[fg=RGB(255,0,0)]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
94:
How can I change the item's background/backcolor, when the item is selected/checked (radio-buttons)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("Radio 1")
						oitem1:SetProperty("HotBackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
						oitem1:SetProperty("SelBackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
						oitem1:SetProperty("SelHotBackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
						oitem1:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
						oitem1:Radio := .T.
						oitem1:RadioGroup := 100
						oitem1:Checked := .T.
					oitem2 := oItems1:Add("Radio 2")
						oitem2:SetProperty("HotBackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
						oitem2:SetProperty("SelBackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
						oitem2:SetProperty("SelHotBackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
						oitem2:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
						oitem2:Radio := .T.
						oitem2:RadioGroup := 100
					oItems1:Add(""):ToString := "Radio 3[typ=2][show=1][grp=100][bghot=RGB(255,255,255)][bgsel=RGB(255,0,0)][bgselhot=RGB(255,0,0)]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
93:
How can I change the item's background/backcolor, when the item is selected/checked (check-box)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Check 1")
				oitem:SetProperty("HotBackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
				oitem:SetProperty("SelBackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
				oitem:SetProperty("SelHotBackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
				oitem:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
				oitem:Checked := .T.
				oitem:Check := .T.
			oItems:Add(""):ToString := "Check 2[typ=1][chk=0][show=1][bghot=RGB(255,255,255)][bgsel=RGB(255,0,0)][bgselhot=RGB(255,0,0)]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
92:
How can I prevent showing the border for selected/highlight/hot items

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SetProperty("Background",102/*exMenuSelBorderColor*/,AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
		oItems := oExContextMenu:Items()
			oItems:Add("Item")
			oItems:Add("Item")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
91:
How can I change the item's background/backcolor, when the cursor hovers it (hot)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item"):SetProperty("HotBackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
			oItems:Add(""):ToString := "Item[bghot=RGB(255,0,0)]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
90:
How can I change the item's background/backcolor

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oItems := oExContextMenu:Items()
			oItems:Add("Item"):SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
			oItems:Add("Item"):SetProperty("BackColor",0x1000000)
			oItems:Add(""):ToString := "Item[bg=RGB(255,0,0)]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
89:
How can I specify/assign the item's identifier

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Debug := .T.
		oItems := oExContextMenu:Items()
			oItems:Add("ID 1",0,1000)
			oItems:Add("ID 2"):ID := 1001
			oItems:Add(""):ToString := "ID 3[id=1002]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
88:
How can I show a horizontal separator/line between groups (method 3,EBN color)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2,oitem3
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 259/*exGroupPopupVertical+exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("")
						oitem1:AllowEdit := 3/*exItemEditSlider*/
						oitem1:EditBorder := 0/*exEditBorderNone*/
						oitem1:EditWidth := -128
						oitem1:EditValue := 25
					oitem2 := oItems1:Add("")
						oitem2:Enabled := .F.
						oitem2:SetProperty("BackColor",0x1000000)
						oitem2:ItemHeight := 8
						oitem2:CaptionWidth := 128
					oitem3 := oItems1:Add("")
						oitem3:AllowEdit := 3/*exItemEditSlider*/
						oitem3:EditBorder := 0/*exEditBorderNone*/
						oitem3:EditWidth := -128
						oitem3:EditValue := 25
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
87:
How can I show a horizontal separator/line between groups (method 2,solid color)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2,oitem3
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 259/*exGroupPopupVertical+exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("")
						oitem1:AllowEdit := 3/*exItemEditSlider*/
						oitem1:EditBorder := 0/*exEditBorderNone*/
						oitem1:EditWidth := -128
						oitem1:EditValue := 25
					oitem2 := oItems1:Add("")
						oitem2:Enabled := .F.
						oitem2:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 128,128,128 } )  , .F. ))
						oitem2:ItemHeight := 8
						oitem2:CaptionWidth := 128
					oitem3 := oItems1:Add("")
						oitem3:AllowEdit := 3/*exItemEditSlider*/
						oitem3:EditBorder := 0/*exEditBorderNone*/
						oitem3:EditWidth := -128
						oitem3:EditValue := 25
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
86:
How can I show a horizontal separator/line between groups (method 1,pattern)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2,oitem3,oitem4
	LOCAL oItems,oItems1,oItems2

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 259/*exGroupPopupVertical+exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("")
						oitem1:AllowEdit := 3/*exItemEditSlider*/
						oitem1:EditBorder := 0/*exEditBorderNone*/
						oitem1:EditWidth := -128
						oitem1:EditValue := 25
					oitem2 := oItems1:Add("",2)
						oitem2:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
						oItems2 := oitem2:Items()
							oitem3 := oItems2:Add("")
								oitem3:Enabled := .F.
								oitem3:ItemHeight := 8
								oitem3:CaptionWidth := 128
							oItems2:BackgroundExt := "none[(0,50%-1,100%,2),pattern=0x006,patterncolor=RGB(128,128,128)]"
					oitem4 := oItems1:Add("")
						oitem4:AllowEdit := 3/*exItemEditSlider*/
						oitem4:EditBorder := 0/*exEditBorderNone*/
						oitem4:EditWidth := -128
						oitem4:EditValue := 25
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
85:
How can I show a vertical separator/line between groups (method 3,EBN color)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2,oitem3
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("")
						oitem1:ItemHeight := 128
						oitem1:AllowEdit := 1027/*exItemEditVertical+exItemEditSlider*/
						oitem1:EditBorder := 0/*exEditBorderNone*/
						oitem1:EditWidth := 32
						oitem1:EditValue := 25
					oitem2 := oItems1:Add("")
						oitem2:Enabled := .F.
						oitem2:SetProperty("BackColor",0x1000000)
						oitem2:ItemHeight := 96
						oitem2:CaptionWidth := 8
					oitem3 := oItems1:Add("")
						oitem3:ItemHeight := 128
						oitem3:AllowEdit := 1027/*exItemEditVertical+exItemEditSlider*/
						oitem3:EditBorder := 0/*exEditBorderNone*/
						oitem3:EditWidth := 32
						oitem3:EditValue := 25
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
84:
How can I show a vertical separator/line between groups (method 2,solid color)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2,oitem3
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("")
						oitem1:ItemHeight := 128
						oitem1:AllowEdit := 1027/*exItemEditVertical+exItemEditSlider*/
						oitem1:EditBorder := 0/*exEditBorderNone*/
						oitem1:EditWidth := 32
						oitem1:EditValue := 25
					oitem2 := oItems1:Add("")
						oitem2:Enabled := .F.
						oitem2:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 128,128,128 } )  , .F. ))
						oitem2:ItemHeight := 96
						oitem2:CaptionWidth := 8
					oitem3 := oItems1:Add("")
						oitem3:ItemHeight := 128
						oitem3:AllowEdit := 1027/*exItemEditVertical+exItemEditSlider*/
						oitem3:EditBorder := 0/*exEditBorderNone*/
						oitem3:EditWidth := 32
						oitem3:EditValue := 25
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
83:
How can I show a vertical separator/line between groups (method 1,pattern)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2,oitem3,oitem4
	LOCAL oItems,oItems1,oItems2

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("")
						oitem1:ItemHeight := 128
						oitem1:AllowEdit := 1027/*exItemEditVertical+exItemEditSlider*/
						oitem1:EditBorder := 0/*exEditBorderNone*/
						oitem1:EditWidth := 32
						oitem1:EditValue := 25
					oitem2 := oItems1:Add("",2)
						oitem2:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
						oItems2 := oitem2:Items()
							oitem3 := oItems2:Add("")
								oitem3:Enabled := .F.
								oitem3:ItemHeight := 96
								oitem3:CaptionWidth := 8
							oItems2:BackgroundExt := "none[(50%-1,0,2,100%),pattern=6,patterncolor=RGB(128,128,128)]"
					oitem4 := oItems1:Add("")
						oitem4:ItemHeight := 128
						oitem4:AllowEdit := 1027/*exItemEditVertical+exItemEditSlider*/
						oitem4:EditBorder := 0/*exEditBorderNone*/
						oitem4:EditWidth := 32
						oitem4:EditValue := 25
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
82:
How can I show a pattern on the items

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oItems:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
			oItems:Padding := "2,2,2,12"
			oItems:BackgroundExt := "root[pattern=0x006,patterncolor=RGB(128,128,128),frame=RGB(128,128,128)](bottom[2],bottom[12,text=`<font ;6><fgcolor 808080><off -2> clipboard </off></font></fgcolor>`,align=0x21])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
81:
How can I show a thick frame arround the items

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oItems:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
			oItems:Padding := "2,2,2,12"
			oItems:BackgroundExt := "root[frame=RGB(128,128,128)](bottom[2],bottom[12,text=`<font ;6><fgcolor 808080><off -2> clipboard </off></font></fgcolor>`,align=0x21])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
80:
How can I add some additional icons on the background

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTqlVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yNAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=")
		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 1/*exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oItems:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
			oItems:Padding := "0,0,0,16"
			oItems:BackgroundExt := "root[text=`<img>2</img><font ;6><fgcolor 808080><off -2> clipboard </off></font></fgcolor><img>2</img>`,align=0x21]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
79:
How can I add some additional text on the background

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 1/*exGroupPopup*/
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
			oItems:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
			oItems:Padding := "0,0,0,8"
			oItems:BackgroundExt := "root[text=`<font ;6><fgcolor 808080>clipboard`,align=0x21]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
78:
How can I assign a tooltip to an item (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:ToString := "ToolTip[id=10][ttp=This is a bit of text that should be shown when cursor hovers the item]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
77:
How can I assign a tooltip to an item (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Items():Add("ToolTip"):Tooltip := "This is a bit of text that should be shown when cursor hovers the item"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
76:
How can I assign a spin field to the item (method 2)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Spin")
				oitem:AllowEdit := 512/*exItemEditSpin*/
				oitem:EditWidth := 16
				oitem:EditValue := 15
				oitem:EditBorder := 0/*exEditBorderNone*/
				oitem:SetProperty("EditOption",2/*exEditMaxValue*/,1000)
			oitem1 := oItems:Add("Edit-Spin")
				oitem1:AllowEdit := 513/*exItemEditSpin+exItemEditText*/
				oitem1:EditWidth := -128
				oitem1:EditValue := 15
				oitem1:SetProperty("EditOption",2/*exEditMaxValue*/,1000)
			oitem2 := oItems:Add("Splider-Spin")
				oitem2:AllowEdit := 515/*exItemEditSpin+exItemEditSlider*/
				oitem2:EditWidth := -128
				oitem2:EditValue := 25
				oitem2:EditBorder := 0/*exEditBorderNone*/
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
75:
How can I assign a spin field to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "Spin[id=10][edittype=0x0200][edit=15][border=0][max=1000][editwidth=16],Edit-Spin[id=20][edittype=0x0201][edit=15][max=1000][editwidth=-128],Splider-Spin[id=30][edittype=0x0203][edit=25][border=0][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
74:
How can I add a vertical slider (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:ToString := "Vertical[id=10][edittype=0x0403][edit=25][border=0][height=128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
73:
How can I add a vertical slider (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Vertical")
				oitem:ItemHeight := 128
				oitem:AllowEdit := 1027/*exItemEditVertical+exItemEditSlider*/
				oitem:EditBorder := 0/*exEditBorderNone*/
				oitem:EditWidth := 32
				oitem:EditValue := 25
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
72:
How can I disable an editor (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:ToString := "Disabled[id=10][dis][edittype=0x01][edit=text-box][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
71:
How can I disable an editor (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Disabled")
				oitem:AllowEdit := 1/*exItemEditText*/
				oitem:EditWidth := -128
				oitem:EditValue := "text-box"
				oitem:Enabled := .F.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
70:
How can I lock an editor (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:ToString := "Locked[id=10][edittype=0x0101][edit=disabled text-box][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
69:
How can I lock an editor (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Locked")
				oitem:AllowEdit := 257/*exItemEditReadOnly+exItemEditText*/
				oitem:EditWidth := -128
				oitem:EditValue := "disabled text-box"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
68:
How can I assign a font field to the item (method 2)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Font")
				oitem:AllowEdit := 7/*exItemEditFont*/
				oitem:EditWidth := -128
				oitem:EditValue := "Tahoma"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
67:
How can I assign a font field to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "Font[id=10][edittype=0x07][edit=Tahoma][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
66:
How can I assign a color field to the item (method 2)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Color")
				oitem:AllowEdit := 6/*exItemEditColor*/
				oitem:EditBorder := 0/*exEditBorderNone*/
				oitem:EditWidth := -128
				oitem:EditValue := 255
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
65:
How can I assign a color field to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "Color[id=10][edittype=0x06][edit=#FF0000][border=0][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
64:
How can I assign a scrollbar field to the item (method 2)
PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("ScrollBar")
				oitem:AllowEdit := 5/*exItemEditScrollBar*/
				oitem:EditWidth := -128
				oitem:EditValue := "25"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
63:
How can I assign a scrollbar field to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "ScrollBar[id=10][edittype=0x05][edit=25][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
62:
Is it possible to change the tooltip beging shown when I change the slider/scroll/progress value

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Progress")
				oitem:AllowEdit := 4/*exItemEditProgress*/
				oitem:EditWidth := -128
				oitem:EditValue := 25
				oitem:SetProperty("EditOption",8/*exEditChangeToolTip*/,"`Current value is: ` + value")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
61:
How can I hide the tooltip beging shown when I change the slider/scroll/progress value
PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Progress")
				oitem:AllowEdit := 4/*exItemEditProgress*/
				oitem:EditWidth := -128
				oitem:EditValue := 25
				oitem:SetProperty("EditOption",8/*exEditChangeToolTip*/,"")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
60:
How can I assign a progress field to the item (method 2)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Progress")
				oitem:AllowEdit := 4/*exItemEditProgress*/
				oitem:EditWidth := -128
				oitem:EditValue := 25
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
59:
How can I assign a progress field to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "Progress[id=10][edittype=0x04][edit=25][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
58:
How can I assign a slider field to the item (method 2)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Slider")
				oitem:AllowEdit := 3/*exItemEditSlider*/
				oitem:EditWidth := -128
				oitem:EditValue := 25
			oitem1 := oItems:Add("Slider")
				oitem1:AllowEdit := 3/*exItemEditSlider*/
				oitem1:EditBorder := 0/*exEditBorderNone*/
				oitem1:EditWidth := -128
				oitem1:SetProperty("EditOption",1/*exEditMinValue*/,50)
				oitem1:SetProperty("EditOption",2/*exEditMaxValue*/,450)
				oitem1:SetProperty("EditOption",3/*exEditTickStyle*/,2)
				oitem1:SetProperty("EditOption",4/*exEditTickFrequency*/,50)
				oitem1:SetProperty("EditOption",5/*exEditTickLabel*/,"value = vmin ? '<br><font ;6><b>'+value : ( value = vmax ? '<br><font ;6><b>'+value : ( value = 200 ? '<br><font ;6><b><fgcolor FF0000>'+value : '' ) )")
				oitem1:EditValue := 345
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
57:
How can I assign a slider field to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "Slider[id=10][edittype=0x03][edit=25][editwidth=-128],Slider[id=20][edittype=0x03][edit=345][border=0][min=50][max=450][tick=2][freq=50][ticklabel=value = vmin ? '<br><font ;6><b>'+value : ( value = vmax ? '<br><font ;6><b>'+value : ( value = 200 ? '<br><font ;6><b><fgcolor FF0000>'+value : '' ) )][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
56:
How can I assign a mask (time) field to the item (method 2)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Time")
				oitem:AllowEdit := 2/*exItemEditMask*/
				oitem:EditWidth := -128
				oitem:EditMask := "99:00:00;;0;overtype,warning=Invalid character"
				oitem:EditValue := "123456"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
55:
How can I assign a mask (time) field to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "Time[id=10][edittype=0x02][edit=12:34:56][mask=99:00:00;;0;overtype,warning=Invalid character][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
54:
How can I assign a mask (license key) field to the item (method 2)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("License Key")
				oitem:AllowEdit := 2/*exItemEditMask*/
				oitem:EditWidth := -128
				oitem:EditMask := "AAAA-AAAA-AAAA-AAAA"
				oitem:EditValue := "1234"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
53:
How can I assign a mask (license key) field to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "License Key[id=10][edittype=0x02][edit=1234-____-____-____][mask=AAAA-AAAA-AAAA-AAAA][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
52:
How can I assign a mask (IP address) field to the item (method 2)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("IP Address")
				oitem:AllowEdit := 2/*exItemEditMask*/
				oitem:EditWidth := -128
				oitem:EditMask := "{0,255}.{0,255}.{0,255}.{0,255}"
				oitem:EditValue := "1.2.3.4"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
51:
How can I assign a mask (IP address) field to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "IP Address[id=10][edittype=0x02][edit=1.2.3.4][mask={0,255}.{0,255}.{0,255}.{0,255}][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
50:
How can I assign a mask (phone) field to the item (method 2)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Phone")
				oitem:AllowEdit := 2/*exItemEditMask*/
				oitem:EditWidth := -128
				oitem:EditMask := "!(9999) 000 000;;;empty,select=4,overtype,beep"
				oitem:EditValue := "0771638317"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
49:
How can I assign a mask (phone) field to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "Phone[id=10][edittype=0x02][edit=(0771) 638 317][mask=!(9999) 000 000;;;empty,select=4,overtype,beep][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
48:
How can I assign a mask (date) field to the item (method 2)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("")
				oitem:AllowEdit := 2/*exItemEditMask*/
				oitem:EditWidth := -128
				oitem:EditMask := "`Date: `{1,12}/{1,31}/{1950,2050};;;select=1"
				oitem:EditValue := "02/15/2015"
			oitem1 := oItems:Add("Date")
				oitem1:AllowEdit := 2/*exItemEditMask*/
				oitem1:EditWidth := -128
				oitem1:EditMask := "!00/00/0000;;0;empty,validateas=1,invalid=Invalid date!,warning=Invalid character!,select=4,overtype"
				oitem1:EditValue := "02/15/2015"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
47:
How can I assign a mask (date) field to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "[id=10][edittype=0x02][edit=Date: 2/15/2015][mask=`Date: `{1,12}/{1,31}/{1950,2050};;;select=1][editwidth=-128],Date[id=20][edittype=0x02][edit=02/15/2015][mask=!00/00/0000;;0;empty,validateas=1,invalid=Invalid date!,warning=Invalid character!,select=4,overtype][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
46:
How can I assign a mask (integer) field to the item (method 2)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Integer")
				oitem:AllowEdit := 2/*exItemEditMask*/
				oitem:EditWidth := -128
				oitem:EditMask := ";;;float,grouping=,digits=0"
				oitem:EditValue := 1000
			oitem1 := oItems:Add("Integer-Grouping")
				oitem1:AllowEdit := 2/*exItemEditMask*/
				oitem1:EditWidth := -128
				oitem1:EditMask := ";;;float,decimal=,digits=0,select=1"
				oitem1:EditValue := 1000
			oitem2 := oItems:Add("Integer-In-Range")
				oitem2:AllowEdit := 2/*exItemEditMask*/
				oitem2:EditWidth := -128
				oitem2:EditMask := "{0,2050}"
				oitem2:EditValue := 1000
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
45:
How can I assign a mask (integer) field to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "Integer[id=10][edittype=0x02][edit=1000][mask=;;;float,grouping=,digits=0][editwidth=-128],Integer-Grouping[id=20][edittype=0x02][edit=1,000][mask=;;;float,decimal=,digits=0,select=1][editwidth=-128],Integer-In-Range[id=30][edittype=0x02][edit=1000][mask={0,2050}][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
44:
How can I assign a mask field to the item (method 2)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Mask")
				oitem:AllowEdit := 2/*exItemEditMask*/
				oitem:EditWidth := -128
				oitem:EditMask := ";;;float,select=1"
				oitem:EditValue := 1000
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
43:
How can I assign a mask field to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "Text-Box[id=10][edittype=0x02][edit=1,000][mask=;;;float,select=1][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
42:
How can I assign an edit / text-box to the item (method 2)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("Mask")
				oitem:AllowEdit := 1/*exItemEditText*/
				oitem:EditValue := "this is a text"
				oitem:EditWidth := -128
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
41:
How can I assign an edit / text-box to the item (method 1)

PROCEDURE OnEditChange(oExContextMenu,Itm)
	DevOut( Transform(Itm,"") )
RETURN

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:EditChange := {|Itm| OnEditChange(oExContextMenu,Itm)} /*Occurs when the user alters the item's text box field.*/

		oExContextMenu:ToString := "Text-Box[edit=this is a text][editwidth=-128]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
40:
How can I display a tab into the context menu (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1
	LOCAL oItems,oItems1,oItems2,oItems3

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SetProperty("Background",102/*exMenuSelBorderColor*/,AutomationTranslateColor( GraMakeRGBColor  ( { 240,240,240 } )  , .F. ))
		oItems := oExContextMenu:Items()
			oItems:ToString := "[id=0][group=0x0103][itemspad=4,4,4,4]([id=-10][group=0x03](),[id=0][bg=RGB(240,240,240)][group=0x03][itemspad=4,4,4,4]([id=-100]))"
			oItems1 := oItems:item(-10):Items()
				oItems1:Add("",0,0):Padding := "8,0,0,0"
				oitem := oItems1:Add("New Page")
					oitem:ToString := "[typ=2][chk=1][spchk=-1][show=1][grp=10][bghot=RGB(255,255,255)][bgsel=RGB(240,240,240)][bgselhot=RGB(240,240,240)][height=16][group=0x03][tab=-100][pad=2,0,2,0]([id=50][group=0x03]([]))"
					oitem:Caption := "Page<off -5><font ;5><b>1</b></font></off>"
					oItems2 := oitem:Items()
						oItems2:Add("add here fields for page 1"):Enabled := .F.
				oitem1 := oItems1:Add("New Page")
					oitem1:ToString := "[typ=2][chk=0][spchk=-1][show=1][grp=10][bghot=RGB(255,255,255)][bgsel=RGB(240,240,240)][bgselhot=RGB(240,240,240)][height=16][group=0x03][tab=-100][pad=2,0,2,0]([id=50][group=0x03]([]))"
					oitem1:Caption := "Page<off -5><font ;5><b>2</b></font></off>"
					oItems3 := oitem1:Items()
						oItems3:Add("add here fields for page 2"):Enabled := .F.
				oItems1:Add("",0,0):Padding := "8,0,0,0"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
39:
How can I add check-buttons to items, without showing the check-box (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2,oitem3
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("Check 1")
						oitem1:Check := .T.
						oitem1:Checked := .T.
						oitem1:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
					oitem2 := oItems1:Add("Check 2")
						oitem2:Check := .T.
						oitem2:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
					oitem3 := oItems1:Add("Check 3")
						oitem3:Check := .T.
						oitem3:Checked := .T.
						oitem3:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
38:
How can I add check-buttons to items, without showing the check-box (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:ToString := "[group=0x3](Check 1[chk=1][show=1],Check 2[chk=0][show=1],Check 3[chk=1][show=1])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
37:
How can I add radio buttons to items, without showing the radio-buttons (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2,oitem3
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("Radio 1",,1000)
						oitem1:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
						oitem1:Radio := .T.
						oitem1:RadioGroup := 100
					oitem2 := oItems1:Add("Radio 2",,1001)
						oitem2:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
						oitem2:Radio := .T.
						oitem2:RadioGroup := 100
					oitem3 := oItems1:Add("Radio 2",,1003)
						oitem3:ShowCheckedAsSelected := 1/*exDisplayItemHighlight*/
						oitem3:Radio := .T.
						oitem3:RadioGroup := 100
					oItems1:item(1000):Checked := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
36:
How can I add radio buttons to items, without showing the radio-buttons (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:ToString := "[group=0x3](Radio 1[rad=1][show=1][grp=100][id=1000],Radio 2[rad=0][show=1][grp=100][id=1001],Radio 2[rad=0][show=1][grp=100][id=1002])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
35:
How can I add check-buttons to items (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("Check 1")
						oitem1:Check := .T.
						oitem1:Checked := .T.
					oItems1:Add("Check 2"):Check := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
34:
How can I add check-buttons to items (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:ToString := "[group=0x3](Check 1[chk=1],Check 2[chk=0])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
33:
How can I add radio buttons to items (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2,oitem3
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 1/*exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("Radio 1",,1000)
						oitem1:Radio := .T.
						oitem1:RadioGroup := 100
					oitem2 := oItems1:Add("Radio 2",,1001)
						oitem2:Radio := .T.
						oitem2:RadioGroup := 100
					oitem3 := oItems1:Add("Radio 2",,1003)
						oitem3:Radio := .T.
						oitem3:RadioGroup := 100
					oItems1:item(1000):Checked := .T.
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
32:
How can I add radio buttons to items (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:ToString := "[group=0x1](Radio 1[rad=1][grp=100][id=1000],Radio 2[rad=0][grp=100][id=1001],Radio 2[rad=0][grp=100][id=1002])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
31:
How can I change the selection/highlighting color

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SetProperty("SelBackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 0,0,0 } )  , .F. ))
		oExContextMenu:SetProperty("Background",102/*exMenuSelBorderColor*/,AutomationTranslateColor( GraMakeRGBColor  ( { 128,0,0 } )  , .F. ))
		oExContextMenu:SetProperty("Background",111/*exMenuHotForeColor*/,AutomationTranslateColor( GraMakeRGBColor  ( { 255,255,255 } )  , .F. ))
		oExContextMenu:ToString := "[group=3](Item 1[chk],Item 2[chk])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
30:
How can I prevent showing/hide the border on the selected/highlighted item

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SetProperty("Background",102/*exMenuSelBorderColor*/,oExContextMenu:SelBackColor())
		oExContextMenu:ToString := "Item 1,Item 2"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
29:
How can I display a tab into the context menu (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SetProperty("Background",102/*exMenuSelBorderColor*/,AutomationTranslateColor( GraMakeRGBColor  ( { 240,240,240 } )  , .F. ))
		oExContextMenu:ToString := "[id=10][group=0x0103][itemspad=4,4,4,4]([id=20][group=0x03]([id=30][pad=8,0,0,0],Page<off -5><font ;5><b>1</b></font></off>[id=40][typ=2][chk=1][spchk=-1][show=1][grp=10][bghot=RGB(255,255,255)][bgsel=RGB(240,240,240)][bgselhot=RGB(240,240,240)][height=16][group=0x03][tab=9000][pad=2,0,2,0]([id=50][group=0x03](add here fields for page 1[dis])),Page<off -5><font ;5><b>2</b></font></off>[id=120][typ=2][spchk=-1][show=1][grp=10][bghot=RGB(255,255,255)][bgsel=RGB(240,240,240)][bgselhot=RGB(240,240,240)][height" +;
		"=16][group=0x03][tab=9000][pad=2,0,2,0]([id=130][group=0x03](add here fields for page 2[dis])),[id=180][pad=8,0,0,0]),[id=190][bg=RGB(240,240,240)][group=0x03][itemspad=4,4,4,4]([id=9000]))"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
28:
How do I prevent highlighting the item (method 2.b)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("No highlight"):Enabled := .F.
			oItems:Add("Item 2")
			oItems:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
27:
How do I prevent highlighting the item (method 2.a)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("No highlight",2)
				oitem:Items():Add("")
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
			oItems:Add("Item 2")
			oItems:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
26:
How do I prevent highlighting the item (method 1.b)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Items():ToString := "No highlight[dis],Item 2,Item 3"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
25:
How do I prevent highlighting the item (method 1.a)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Items():ToString := "No highlight[group=0x3][arrow=0]([]),Item 2,Item 3"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
24:
How can I can I assign pictures or images for the item (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SetProperty("HTMLPicture","pic1","c:\exontrol\images\zipdisk.gif")
		oExContextMenu:SetProperty("HTMLPicture","pic2","c:\exontrol\images\auction.gif")
		oItems := oExContextMenu:Items()
			oItems:Add("Item"):HTMLImage := "pic1"
			oItems:Add("Item"):HTMLImage := "pic2"
			oItems:Add("",1)
			oItems:Add("Item <img>pic1</img>")
			oItems:Add("Item <img>pic2</img>")
			oItems:Add("",1)
			oItems:Add("<img>pic1</img> Item <img>pic2</img>")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
23:
How can I can I assign pictures or images for the item (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:SetProperty("HTMLPicture","pic1","c:\exontrol\images\zipdisk.gif")
		oExContextMenu:SetProperty("HTMLPicture","pic2","c:\exontrol\images\auction.gif")
		oExContextMenu:ToString := "Item[himg=pic1],Item[himg=pic2],[sep],Item <img>pic1</img>,Item <img>pic2</img>,[sep],<img>pic1</img> Item <img>pic2</img>"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
22:
How can I can I assign icons for the item (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTqlVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yNAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=")
		oItems := oExContextMenu:Items()
			oItems:Add("Item"):Image := 1
			oItems:Add("Item"):Image := 2
			oItems:Add("",1)
			oItems:Add("Item <img>1</img>")
			oItems:Add("Item <img>2</img>")
			oItems:Add("",1)
			oItems:Add("Item <img>1</img>"):Image := 1
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
21:
How can I can I assign icons for the item (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTqlVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yNAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=")
		oExContextMenu:Items():ToString := "Item[img=1],Item[img=2],[sep],Item <img>1</img>,Item <img>2</img>,[sep],Item <img>1</img>[img=1]"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
20:
How can I change the visual appearance / background color (EBN) for a collection of items/group (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oItems := oExContextMenu:Items()
			oItems:Padding := "2,2,2,2"
			oItems:SetProperty("BackColor",0x1000000)
			oItems:Add("Item 1")
			oItems:Add("Item 2")
			oItems:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
19:
How can I change the visual appearance / background color (EBN) for a collection of items/group (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oExContextMenu:Items():ToString := "[itemsbg=0x1000000][itemspad=2,2,2,2][group=0x103](Item 1,Item 2,Item 3)"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
18:
How can I change the background color for a collection of items/group (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Padding := "2,2,2,2"
			oItems:SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
			oItems:Add("Item 1")
			oItems:Add("Item 2")
			oItems:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
17:
How can I change the background color for a collection of items/group (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Items():ToString := "[itemsbg=RGB(255,0,0)][itemspad=2,2,2,2][group=0x103](Item 1,Item 2,Item 3)"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
16:
How can I change the visual appearance / background color (EBN) for a specified item (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oItems := oExContextMenu:Items()
			oItems:Add("Item 1")
			oItems:Add("Item 2"):SetProperty("BackColor",0x1000000)
			oItems:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
15:
How can I change the visual appearance / background color (EBN) for a specified item (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:VisualAppearance():Add(1,"c:\exontrol\images\normal.ebn")
		oExContextMenu:Items():ToString := "Item 1,Item 2[bg=0x1000000],Item 3"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
14:
How can I change the background color for a specified item (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item 1")
			oItems:Add("Item 2"):SetProperty("BackColor",AutomationTranslateColor( GraMakeRGBColor  ( { 255,0,0 } )  , .F. ))
			oItems:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
13:
How can I change the background color for a specified item (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Items():ToString := "Item 1,Item 2[bg=RGB(255,0,0)],Item 3"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
12:
How do I add a popup or a sub-menu so it show when cursor hovers it (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems1 := oItems:Add("Popup",2):Items()
				oItems1:Add("Item 1")
				oItems1:Add("Item 2")
				oItems1:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
11:
How do I add a popup or a sub-menu so it show when cursor hovers it (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Items():ToString := "Popup(Item 1,Item 2,Item 3)"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
10:
How can I arrange the items by grouping (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2,oitem3
	LOCAL oItems,oItems1,oItems2,oItems3,oItems4

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
				oItems1 := oitem:Items()
					oitem1 := oItems1:Add("Horizontal",2)
						oitem1:GroupPopup := 1/*exGroupPopup*/
						oItems2 := oitem1:Items()
							oItems2:Add("Sub-Item <b>A</b>")
							oItems2:Add("Sub-Item <b>B</b>")
							oItems2:Add("Sub-Item <b>C</b>")
					oItems1:Add(""):CaptionWidth := 16
					oitem2 := oItems1:Add("Vertical",2)
						oitem2:Alignment := 1/*exCenter*/
						oitem2:GroupPopup := 257/*exGroupPopupVertical+exGroupPopup*/
						oItems3 := oitem2:Items()
							oItems3:Add("Sub-Item <b>A</b>")
							oItems3:Add("Sub-Item <b>B</b>")
							oItems3:Add("Sub-Item <b>C</b>")
					oItems1:Add(""):CaptionWidth := 16
					oitem3 := oItems1:Add("Popup",2)
						oItems4 := oitem3:Items()
							oItems4:Add("Sub-Item <b>A</b>")
							oItems4:Add("Sub-Item <b>B</b>")
							oItems4:Add("Sub-Item <b>C</b>")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
9:
How can I arrange the items by grouping (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Items():ToString := "[group=0x03](Horizontal[group=0x01](Sub-Item <b>A</b>,Sub-Item <b>B</b>,Sub-Item <b>C</b>),[captionwidth=16],Vertical[group=0x0101][align=1](Sub-Item <b>A</b>,Sub-Item <b>B</b>,Sub-Item <b>C</b>),[captionwidth=16],Popup(Sub-Item <b>A</b>,Sub-Item <b>B</b>,Sub-Item <b>C</b>),[captionwidth=160])"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
8:
How can I arrange some items vertically, and some horizontally (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem,oitem1,oitem2
	LOCAL oItems,oItems1,oItems2,oItems3

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oItems1 := oitem:Items()
					oItems1:Add("1")
					oItems1:Add("2")
					oItems1:Add("3")
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
			oitem1 := oItems:Add("",2)
				oItems2 := oitem1:Items()
					oItems2:Add("4")
					oItems2:Add("5")
					oItems2:Add("6")
				oitem1:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
			oitem2 := oItems:Add("",2)
				oItems3 := oitem2:Items()
					oItems3:Add("7")
					oItems3:Add("8")
					oItems3:Add("9")
				oitem2:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
7:
How can I arrange some items vertically, and some horizontally (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Items():ToString := "[group=3](1,2,3),[group=3](4,5,6),[group=3](7,8,9)"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
6:
How can I assign multiple-lines to an item (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oItems1 := oitem:Items()
					oItems1:Add("Item 1"):Caption := "Item <br><c><b>1"
					oItems1:Add("Item 2"):Caption := "Item <br><c><b>2"
					oItems1:Add("Item 3"):Caption := "Item <br><c><b>3"
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
5:
How can I assign multiple-lines to an item (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Items():ToString := "[group=3](Item <br><c><b>1,Item <br><c><b>2,Item <br><c><b>3)"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
4:
How can I add new items arranged horizontally to the context menu (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oitem
	LOCAL oItems,oItems1

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oitem := oItems:Add("",2)
				oItems1 := oitem:Items()
					oItems1:Add("Item 1")
					oItems1:Add("Item 2")
					oItems1:Add("Item 3")
				oitem:GroupPopup := 3/*exNoGroupPopupFrame+exGroupPopup*/
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
3:
How can I add new items arranged horizontally to the context menu (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Items():ToString := "[group=3](Item 1,Item 2,Item 3)"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
2:
How can I add new items to the context menu (method 2)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu
	LOCAL oItems

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oItems := oExContextMenu:Items()
			oItems:Add("Item 1")
			oItems:Add("Item 2")
			oItems:Add("Item 3")
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN
1:
How can I add new items to the context menu (method 1)

#include "AppEvent.ch"
#include "ActiveX.ch"

PROCEDURE Main
 	LOCAL oForm
	LOCAL nEvent := 0, mp1 := NIL, mp2 := NIL, oXbp := NIL
	LOCAL oExContextMenu

	oForm := XbpDialog():new( AppDesktop() )
	oForm:drawingArea:clipChildren := .T.
	oForm:create( ,,{100,100}, {640,480},, .F. )
	oForm:close  := {|| PostAppEvent( xbeP_Quit )}

	oExContextMenu := XbpActiveXControl():new( oForm:drawingArea )
	oExContextMenu:CLSID  := "Exontrol.ContextMenu.1" /*{2DFBF6CB-9198-4576-AB91-EE6445C1F3E0}*/
	oExContextMenu:create(,, {10,60},{610,370} )

		oExContextMenu:Items():ToString := "Item 1,Item 2,Item 3"
		oExContextMenu:Select()

	oForm:Show()
	DO WHILE nEvent != xbeP_Quit
		nEvent := AppEvent( @mp1, @mp2, @oXbp )
		oXbp:handleEvent( nEvent, mp1, mp2 )
	ENDDO 
RETURN