Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / Clipboard Reading/Erasing with user32.dll

Author
Message
culmor30
17
Years of Service
User Offline
Joined: 16th Jun 2007
Location: In my head.
Posted: 25th Apr 2008 04:34
Hey, I've been trying to make this little app that will display the content of the clipboard and then erase it just for fun (which I will add later). I came across this little problem though, this isn't working for me:



Any idea what's wrong? I can't see why it wouldn't work... do I need to use another method to get the return value from the DLL Call? Try it out, it just says

Your Clipboard Contains:


...That's all.

Thanks in advance.
culmor30
17
Years of Service
User Offline
Joined: 16th Jun 2007
Location: In my head.
Posted: 25th Apr 2008 05:45
Well, I don't know if this relates, but I used Styx to print the window handle on screen. Should I use this numerical value for the window handle user32 wants?
jinzai
18
Years of Service
User Offline
Joined: 19th Aug 2006
Location: USA
Posted: 25th Apr 2008 08:35 Edited at: 25th Apr 2008 08:37
Yes, but you could also pass NULL, or 0 to the function, which only opens the clipboard for your app. The return is a simple boolean, 1 for it worked, 0 for failure.

Are you aware of the DBPro command get clipboard$()?
culmor30
17
Years of Service
User Offline
Joined: 16th Jun 2007
Location: In my head.
Posted: 26th Apr 2008 03:38
Yes yes, but I wanted to use user32 for DLL practice... or fun.

And I want to use the shared clipboard, so how can I open that?
Dabbler
17
Years of Service
User Offline
Joined: 3rd Mar 2007
Location: Minnesota
Posted: 26th Apr 2008 04:16
I don't know what your level of experience is, but this might help:

http://www.libertybasicuniversity.com/lbnews/nl108/clipboard.htm


Whatever...
culmor30
17
Years of Service
User Offline
Joined: 16th Jun 2007
Location: In my head.
Posted: 26th Apr 2008 06:16
Ahh, thanks much man, that helps a lot. I only found that one clipboard function I was using in Dependency Walker, forgot about other possible functions. If I have any troubles I'll post again, but I don't think I will. Thanks much

Login to post a reply

Server time is: 2024-09-27 14:30:26
Your offset time is: 2024-09-27 14:30:26