  Title Mouse Over Effects
  DIALOG CREATE,Mouse Over Efects,-1,0,250,250
  DIALOG ADD,STYLE,STYLE4,Tahoma,10,BC,DKRED,RED
  DIALOG ADD,STYLE,STYLE3,Tahoma,10,Bi,BACKGROUND,DKBLUE
  DIALOG ADD,STYLE,STYLE2,Tahoma,10,BC,LTGREEN,DKGREEN
  DIALOG ADD,STYLE,STYLE1,Tahoma,10,BC,DKGREEN,LTGREEN

  DIALOG ADD,BUTTON,BUTTON,20,30,80,40,Hello !!,STYLE3
  DIALOG ADD,BUTTON,BUTTON1,20,30,80,40,Hello !!

  DIALOG ADD,CHECK,CHECK,70,30,180,20,Check box,,STYLE3,click
  DIALOG ADD,CHECK,CHECK1,70,30,180,20,Check box

  DIALOG ADD,CHECK,CHECK2,90,30,180,20,Another check,,STYLE1,click
  DIALOG ADD,CHECK,CHECK21,90,30,180,20,Another check,,STYLE2

  DIALOG ADD,PROGRESS,PROGRESS,130,30,80,40
  DIALOG ADD,BUTTON,BUTTON2,132,32,76,36,Hola !!!

  DIALOG ADD,TEXT,back,190,40,100,20,,STYLE2
  DIALOG ADD,TEXT,TEXT,192,42,96,16,Click me !!,STYLE4,click,hand    
  DIALOG ADD,TEXT,TEXT1,192,42,96,16,Click me !!,STYLE1

  DIALOG SHOW

  rem create a list and put in the elementes for mouse over event  
  list create,1
  list loadtext,1
"button1
"text1
"check1
"check21
"progress
  rem end of the list configuration
  :loop 
  %e = @event()
  if %e
    goto %e
  end 

  rem here starts the mouseover code
  %%xyz = 0
  repeat 
    list seek,1,%%xyz
    %y = @diff(@mousepos(y),22)
    rem we reduce %y in 22 pixels due to the window title height
    %x = @diff(@mousepos(x),3)
    rem then reduce %x due to the window 3D border
    rem here we compare the position of the cursor with the 4 element coordenates
    rem @greater(%x,@sum(@dlgpos(@item(1),l),@dlgpos(,l)))
    rem @greater(@sum(@sum(@dlgpos(@item(1),l),@dlgpos(@item(1),w)),@dlgpos(,l)),%x)
    rem @greater(%y,@sum(@dlgpos(@item(1),t),@dlgpos(,t)))
    rem @greater(@sum(@sum(@dlgpos(@item(1),t),@dlgpos(@item(1),h)),@dlgpos(,t)),%y)
    if @equal(1111,@greater(%x,@sum(@dlgpos(@item(1),l),@dlgpos(,l)))@greater(@sum(@sum(@dlgpos(@item(1),l),@dlgpos(@item(1),w)),@dlgpos(,l)),%x)@greater(%y,@sum(@dlgpos(@item(1),t),@dlgpos(,t)))@greater(@sum(@sum(@dlgpos(@item(1),t),@dlgpos(@item(1),h)),@dlgpos(,t)),%y))
      dialog hide,@item(1)
    else 
      dialog show,@item(1)
    end 
    rem replace the over effect with other vds command
    %%xyz = @succ(%%xyz)
  until @equal(%%xyz,@count(1))  

  rem end of the mouseover code  

  goto loop

:buttonBUTTON
:button1BUTTON
:button2BUTTON
:button21BUTTON
:textCLICK
  info Hello from Spain !!!@cr()Hola a todos !!!
  goto loop

:checkCLICK
  if @dlgtext(check)
    dialog set,check1,1
  else 
    dialog set,check1,
  end 
  goto loop

:check2CLICK
  if @dlgtext(check2)
    dialog set,check21,1
  else 
    dialog set,check21,
  end 
  goto loop

:close
  info Adios !!
