dcsimg
Results 1 to 4 of 4

Thread: Screen Recorder Help in VB 2008

  1. #1

    Thread Starter
    Member Giver's Avatar
    Join Date
    Aug 2008
    Posts
    39

    Question Screen Recorder Help in VB 2008

    Hi, I want to make a screen recorder that takes a screenshot of the screen every so often then compresses the image to an .avi file.
    This code is what I have made. It doesn't work and I don't really know how to make it work.
    Please help.
    Code:
    Imports System.IO
    
    Public Class Form1
        Dim Screen As New Bitmap(My.Computer.Screen.Bounds.Width, My.Computer.Screen.Bounds.Height)
        Dim Screensize As New Size(My.Computer.Screen.Bounds.Width, My.Computer.Screen.Bounds.Height)
        Dim G As Graphics = Graphics.FromImage(Screen)
        Dim Stream As New FileStream("C:\Documents and Settings\HP_Administrator\My Documents\Neal\Videos and Sounds\TestVideo.avi", FileMode.Append)
    
        Private Sub BtnStart_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnStart.Click
            TmrCapture.Start() 'Starts the Timer
        End Sub
    
        Private Sub BtnStop_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnStop.Click
            TmrCapture.Stop() 'Stops the Timer
        End Sub
    
        Private Sub TmrCapture_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TmrCapture.Tick
            G.CopyFromScreen(New Point, New Point, Screensize) 'Takes a screen shot of the screen
            Screen.Save(Stream, Imaging.ImageFormat.Bmp) 'saves the screen shot to the following stream
        End Sub
    End Class

  2. #2
    Hyperactive Member
    Join Date
    Apr 2008
    Posts
    312

    Re: Screen Recorder Help in VB 2008

    i spent ages trying to find out how to make one once, never got any were. ost peeps would make this in c+ what i would recomend is having a search in www.planet-source-code.com u can get most stuff from there.

    hope it helps

  3. #3

    Thread Starter
    Member Giver's Avatar
    Join Date
    Aug 2008
    Posts
    39

    Re: Screen Recorder Help in VB 2008

    It didn't, I couldn't find anything.

  4. #4
    Member
    Join Date
    Apr 2009
    Posts
    37

    Re: Screen Recorder Help in VB 2008

    Non-Work

Posting Permissions

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



Featured


Click Here to Expand Forum to Full Width