Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.sys.acorn.programmer > #5675
| From | Fred Graute <fjgraute@planet.nl> |
|---|---|
| Newsgroups | comp.sys.acorn.programmer |
| Subject | Re: loading the clipboard |
| Date | 2019-01-04 02:31 +0100 |
| Organization | None |
| Message-ID | <6010d97057.fjgraute@casema.nl> (permalink) |
| References | <19191f7057.jim@6.abbeypress.net> <9c6da17057.jim@6.abbeypress.net> |
In message <9c6da17057.jim@6.abbeypress.net>
Jim Nagel <jnews18c@abbeypress.co.uk> wrote:
> Jim Nagel wrote on 2 Jan:
>
> > From within a program, is there a way of loading a specified string onto
> > the clipboard? It used to be possible in Ro4.39 but the routine I had
> > there does not work in Ro5.
>
> Found the routine I was using on the RiscPC (4.39). It used
> SYS "ClipboardHolder_Copy" ,0,&FFF,A$,L%
> but RiscOS 5 does not (yet) provide that SYS call.
> Could it be added? Would surely be widely useful.
For RO5 you can use the Clipboard module. It's currently not available
from the ROOL website but there is a copy in !MiniTime.
The code to use it should be something like this:
String$ = "Test global clipboard"
Length% = LEN(String$)
Leafname$ = "TestClip"
SYS "XClipboard_Put",0,&FFF,String$,Length%,Leafname$,0 TO ;Flags%
IF ((Flags% AND 1) = 1) THEN
SYS "XClipboardHolder_Copy",0,&FFF,String$,Length%
ENDIF
You'll also need to make sure that the Clipboard module is loaded when
ClipboardHolder is absent. Either in the BASIC program or an Obey file.
HTH
--
Fred Graute
http://www.stronged.iconbar.com/
Back to comp.sys.acorn.programmer | Previous | Next — Previous in thread | Find similar | Unroll thread
loading the clipboard Jim Nagel <jnews18c@abbeypress.co.uk> - 2019-01-02 15:40 +0000
Re: loading the clipboard Ronald <gettingchoppy@gmail.com> - 2019-01-03 08:50 +1300
Re: loading the clipboard Jim Nagel <jnews18c@abbeypress.co.uk> - 2019-01-03 15:23 +0000
Re: loading the clipboard Alan Wrigley <usenet@alanwrigley.me.uk> - 2019-01-03 17:09 +0000
Re: loading the clipboard Andrew Conroy <a.m.conroy@owlart.co.uk> - 2019-01-03 21:53 +0000
Re: loading the clipboard Alan Wrigley <usenet@alanwrigley.me.uk> - 2019-01-03 22:45 +0000
Re: loading the clipboard Steve Fryatt <news@stevefryatt.org.uk> - 2019-01-03 23:13 +0000
Re: loading the clipboard Fred Graute <fjgraute@planet.nl> - 2019-01-04 02:31 +0100
csiph-web