Results 1 to 5 of 5

Thread: Easy Screenshot Question

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Jan 2000
    Location
    TX
    Posts
    29
    Heya all!

    I have a really simple question and I can't believe I don't know how to do it...

    I wrote a simple VB program. I need to take a screenshot of a few of the forms in action so I can incorporate them into a PowerPoint Presentation. What is the best way to do so??

    I tried the old ALT/CTRL + PrintScrn command. But, I don't know where the file gets stored. If it can even be done that way...

    I did a search on this and a few other sites. But, it seems that this is such an easy thing that all of the applicable posts I have found assume that I already can get so far as to take a screenshot. Thanks for the help.

    Trick
    Trick

  2. #2
    Frenzied Member
    Join Date
    Jun 2000
    Location
    East Providence, RI
    Posts
    1,715
    the button Print Screen, takes a snap shot of the screen, and then copies it to the clip board.
    NXSupport - Your one-stop source for computer help

  3. #3

    Thread Starter
    Junior Member
    Join Date
    Jan 2000
    Location
    TX
    Posts
    29
    Oh geez, you're kidding?

    Man, how easy was that? I'm going to crawl into my hole and disappear...

    Thank you very much for your time in replying.

    I can't believe I've been around computers as long as I have and couldn't figure that one out or find the information on my own.

    Rightfully humbled,

    Trick

  4. #4
    Guest
    If want to do it through vb code:

    Code:
    Private Declare Sub keybd_event Lib "user32" (ByVal bVk As Byte, ByVal bScan As Byte, _
      ByVal dwFlags As Long, ByVal dwExtraInfo As Long)
    
    Private Const VK_SNAPSHOT = &H2C
    
    
    Public Function SaveScreen(ByVal theFile As String) As Boolean
    On Error Resume Next
    
        'To get the Entire Screen
        Call keybd_event(vbKeySnapshot, 1, 0, 0)
    
        'To get the Active Window
        'Call keybd_event(vbKeySnapshot, 0, 0, 0)
    
        SavePicture Clipboard.GetData(vbCFBitmap), theFile
    
    SaveScreen = True
    Exit Function
    End Function
    
    Usage:
    
    Call SaveScreen("C:\Windows\Desktop\ss.bmp")
    The reason why I showed you this code is because Print Screen will get the whole screen, but if you want to get the Active Window, which is your program, than you can delete the Entire Screen code and leave the Active Window code in (taking out the ' ) and it will place the picture where you decide.

  5. #5

    Thread Starter
    Junior Member
    Join Date
    Jan 2000
    Location
    TX
    Posts
    29
    Ahh, very nice. Thank you very much.

    Scary thing is, I could follow the VB code easily, but didn't know how to do the simple SS in the first place.

    Thanks again for replying.

    Trick

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width