How to paste and get text placed in the clipboard

BlitzMax Forums/BlitzMax Programming/How to paste and get text placed in the clipboard

ziggy(Posted 2006) [#1]
does anyonw know how to do this?


ozak(Posted 2006) [#2]
GadgetCut and GadgetPaste?


WendellM(Posted 2006) [#3]
Thanks to ozak's function mentions:
Strict

Local window:TGadget = CreateWindow( "Copy & Paste Test", 10,30, 400,200, Null,..
                                     WINDOW_TITLEBAR | WINDOW_CLIENTCOORDS )
Local txt1:TGadget = CreateTextArea( 0,0, 200,200, window, TEXTAREA_WORDWRAP )
Local txt2:TGadget = CreateTextArea( 200,0, 200,200, window, TEXTAREA_WORDWRAP )

SetTextAreaText txt1, "The quick brown fox jumps over the lazy dog.~n~n"
AddTextAreaText txt1, "Pack my box with five dozen liquor jugs."

SelectTextAreaText txt1
GadgetCopy txt1
GadgetPaste txt2

Repeat
	WaitEvent
Until EventID() = EVENT_WINDOWCLOSE



ziggy(Posted 2006) [#4]
I was wondering how to copy and paste text to the clipboard without creating any gadget. I'm creating a graphical GUI and I want the drawed TextBox to manipulate the clipboard.

Any idea how to do that?


Beaker(Posted 2006) [#5]
As a last resort you could convert this:
http://www.blitzbasic.com/codearcs/codearcs.php?code=1543
although I believe it can be done without a DLL.


Beaker(Posted 2006) [#6]
http://www.blitzbasic.com/Community/posts.php?topic=53750


ziggy(Posted 2006) [#7]
Many thanks!!!