Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

SetClipboardData

Posted on 1998-09-24
3
Medium Priority
?
180 Views
Last Modified: 2012-06-27
I can't seem to pass the 2nd parameter of this API. Does anyone have an example.
0
Comment
Question by:QAX
  • 2
3 Comments
 
LVL 2

Expert Comment

by:swilt
ID: 1436440
If your in VB why not use clipboard.SetData or clipboard.SetText ?
0
 
LVL 8

Accepted Solution

by:
Answers2000 earned 150 total points
ID: 1436441
What's the first param in your app ?

Second param is a handle to the data-type, for example if using CF_TEXT, handle to a block of ram allocated with GlobalAlloc (block of ram must contain nul terminated text in ASCII)

e.g.
handle = GlobalAlloc
GlobalLock
Fill in memory
GlobalUnlock

SetClipboardData( CF_TEXT, handle ) ;

If passing a bitmap it's the HBITMAP handle (CF_BITMAP) etc.
0
 
LVL 8

Expert Comment

by:Answers2000
ID: 1436442
Oops that should have been a comment
0

Featured Post

Ask an Anonymous Question!

Don't feel intimidated by what you don't know. Ask your question anonymously. It's easy! Learn more and upgrade.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses

824 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question