Does anybody have a simple example of getting a %gr image onto the clipboard
The method have been using has stopped working
thanks
steve
Welcome to our forums
Does anybody have a simple example of getting a %gr image onto the clipboard
The method have been using has stopped working
thanks
steve
This works for me. (FTN ver 9.00). After pressing the TOCB menu item, I can paste the graphics region into word etc.
winapp
module s_mod
use clrwin
implicit none
integer gw, gh
contains
subroutine setup
integer iw
gw = 0.8*clearwin_info@('SCREEN_WIDTH')
gh = 0.8*clearwin_info@('SCREEN_DEPTH')
iw = winio@('%mn[Exit]&','Exit')
iw = winio@('%mn[TOCB]&',TO_CB) !Copy %gr to clipboard.
iw = winio@('%gr[red]&',gw,gh)
iw = winio@('')
end subroutine setup
integer function TO_CB()
integer i
i = GRAPHICS_TO_CLIPBOARD@(0,0,gw-1,gh-1)
if (i .eq. 1) print*, 'Success. Graphics region copied to clipboard.'
if (i .ne. 1) print*, 'Failed. Graphics region not copied to clipboard.'
TO_CB = 2
end function TO_CB
end module s_mod
program main
use s_mod
call setup
end
Kenneth
your solution resolved the issues
Im still having problems using metafiles_to_clipboard() (EMF files) but this is not critical
thanks
steve