BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Re: Reading the clipboard

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> comp.lang.pascal.delphi.misc
View previous topic :: View next topic  
Author Message
Maarten Wiltink
Guest





PostPosted: Sat Jan 17, 2004 12:44 pm    Post subject: Re: Reading the clipboard Reply with quote



"Ciarán Ó Duibhín" <ciaran (AT) oduibhin (DOT) freeserve.co.uk> wrote


Quote:
This piece of code, taken from a help file, shows how many "formats"
are on the clipboard and what they are:

ShowMessage ('No of clipboard formats: ' + IntToStr
(ClipBoard.FormatCount));
for i := 0 to ClipBoard.FormatCount-1 do
ShowMessage (IntToStr(ClipBoard.Formats[i]))
end;

The trouble is that the values returned in the ClipBoard.Formats
array are just integers. The meanings of some of them can be found
in the Delphi 5 source (windows.pas), e.g. 1 = CF_TEXT, 7 = CF_OEMTEXT,
etc, but some of the values I am getting are in the range 50000-60000
and I can find no explanation of them. (I am working with a clipboard
containing material copied from within Word 2000, and I am using Win95.)

Applications can register their own clipboard formats, if I am not
mistaken. Office applications probably do so extensively, in the
interest of integration (with other Office applications, obviously).
It may or may not be documented how those formats work. But I bet
Google knows anyway. Don't forget to search for hex values, too.

Groetjes,
Maarten Wiltink



Back to top
Jamie
Guest





PostPosted: Sat Jan 17, 2004 8:23 pm    Post subject: Re: Reading the clipboard Reply with quote



Registered clipboard formats are identified by values in the range
0xC000 through 0xFFFF.
This only means that what your getting is custom clipboard formats
made by apps that are most likely communicating with each other in some
way that they understand.
Packages like Office for WIndows, Corel etc...


Ciarán Ó Duibhín wrote:

Quote:
This piece of code, taken from a help file, shows how many "formats" are on
the clipboard and what they are:

ShowMessage ('No of clipboard formats: ' + IntToStr
(ClipBoard.FormatCount));
for i := 0 to ClipBoard.FormatCount-1 do
ShowMessage (IntToStr(ClipBoard.Formats[i]))
end;

The trouble is that the values returned in the ClipBoard.Formats array are
just integers. The meanings of some of them can be found in the Delphi 5
source (windows.pas), e.g. 1 = CF_TEXT, 7 = CF_OEMTEXT, etc, but some of the
values I am getting are in the range 50000-60000 and I can find no
explanation of them. (I am working with a clipboard containing material
copied from within Word 2000, and I am using Win95.)

Thanks for any ideas,
Ciarán Ó Duibhín.




Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> comp.lang.pascal.delphi.misc All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.