Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Repost - Take screen shot of form and email it Help!!! 1

Status
Not open for further replies.

at51178

Technical User
Mar 25, 2002
587
0
0
US
I would like to create a button where upon clicking on it it will take a screen shot of the form and automatically open up my outlook email if it is not open and paste it to my email is there any way of doing this I have been looking everywhere on the web to see if this could be done.
 
That's a good question. Behind that button, you'd need code to emulate:

- clicking the print screen button.
- using sendobject with the contents of the clipboard

So, you'd need the code that represents the print screen key to click it behind your button. That might be the easy part. The hard part might be putting the clipboard contents in the sendobject code.

I don't know the answer, but I'm marking this one because I'm interested in learning how as well.

Jim DeGeorge [wavey]
 
Jim, I think you're right, I think this one may be a bit complicated.

I tried a little earlier using SendKeys "{PRTSC}" but it didn't work. I don't know if there's another keycode constant or VB method that will do it. And that's an imperfect solution in any event, because that will capture the entire desktop, not just the active window or current form.

I suppose you could shell out to a 3rd-party screen capture utility, but I've never coded anything quite like that. And there remains the problem of getting the image into an e-mail once you've got it captured.

I think I'll mark this thread, too. I'm interested to see where this goes...

Ken S.
 
Someone asked how to do this, but instead of email, they wanted the screen pasted into PowerPoint. So this thread thread702-689314 shows you how to do that. It's at least a start. I'll see if I can figure out how to do it in Outlook.
 
Thanks a lot guys


I will be looking at the code for that thread and see if I can adapt it to my project.

I would of thought something like this would of been a little easier guess not.


I will be doing some more research on my end if you find anything please let me know

thanks for all your help I appreciate it
 
Fancy

Boy, that's close. I didn't even think that was possible! I'm sure that what at51178 needs isn't far off. Have a star here and on the other post from me!

Jim DeGeorge [wavey]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top