I was playing around with child windows and wanted to add a 'standard' background color using the WINSTYLE@ function. Using it, however, caused a crash 'unused arguments' at run-time in line 8 (the %sh).
winapp
program main
use mswin
integer:: ii, ctrl, wd=-999, ht=-999,x=-999,y=-999
integer,external:: call_back
!child window with controls...
call winstyle@('%bg[white]&')
ii=winio@('%sh&',ctrl)
ii=winio@('%bt[Button]&')
ii=winio@('%bt[Button]&')
ii=winio@('%bt[Button]&')
ii=winio@('%bt[Button]&')
ii=winio@('%bt[Button]&')
ii=winio@('%bt[Button]&')
ii=winio@('%bt[Button]%nl&')
ii=winio@('%bt[Button]%nl&')
ii=winio@('%bt[Button]%nl&')
ii=winio@('%bt[Button]%nl&')
ii=winio@('%bt[Button]%nl&')
ii=winio@('%bt[Button]%nl&')
ii=winio@('%bt[Button]%nl&')
ii=winio@('%bt[Button]%nl&')
ii=winio@('%bt[Button]%nl&')
ii=winio@('%bt[Button]%nl&')
ii=winio@('%bt[Button]&')
ii=winio@(' ')
call get_window_location@(ctrl,x,y,wd,ht)
print *,x,y,wd,ht
!Main window to display child with vertical scroll bar...
wd = 280; ht = 150
ii=winio@('%ww[not_fixed_size]%sz&',wd,ht)
! ii = winio@('%`mv&',call_back)
ii=winio@('%ch[hscrollbar,vscrollbar]',ctrl)
end
integer function call_back()
use mswin
character*32:: callback_reason
call_back = 1
callback_reason=clearwin_string@('CALLBACK_REASON')
print *,callback_reason
return
end