its C++ but this can be placed in a console application,
Controls:
S - for PrintScreen
E - to Exit the program.
all what this does is simulate a button. if im correct u can do this with VB too
Code:
Sendkeys.Send(VK_SNAPSHOT)
Try something like this for direct capture:
[php]
Dim screenRectangle = My.Computer.Screen.Bounds
Dim myBmp As New Bitmap(screenRectangle.Width, screenRectangle.Height)
Using mGraphics As Graphics = Graphics.FromImage(myBmp)
mGraphics.CopyFromScreen(New Point(0, 0), Point.Empty, screenRectangle.Size)
End Using
Clipboard.SetImage(myBmp)
[/php]
its C++ but this can be placed in a console application,
Controls:
S - for PrintScreen
E - to Exit the program.
all what this does is simulate a button. if im correct u can do this with VB too
Code:
Sendkeys.Send(VK_SNAPSHOT)
Please, keep C++ in the C++ section for god's sake.
ahw... this SendKeys.Send(Keys.Printscreen) :/ well mine is below idk if this is correct /
[php]Public Class Main_Form 'or console app :/'
Public Declare Function GetAsyncKeyState Lib "user32" (ByVal vKey As Long) As Integer
Dim Exit as Boolean = GetAsyncKeystate(Keys.E)
Dim PRINTS as Boolean = GetAsyncKeyState(Keys.S)
Private Sub Main_Form_Load(Byval Sender as System.object, Byval e Systen.EventArgs) Handles MyBase.Load
Timerx.Start
end sub
Private Sub Timerx_Tick(Byval Sender as System.object, Byval e Systen.EventArgs) Handles Timerx.Tick 'x = probably 1...'
if Exit = True then
Me.Close()
End If
if PRINTS = True then
SendKeys.Send(VK_SNAPSHOT)
Textboxx.Text += "SnapShot Taken." & VB_Return 'or something...'
System.Threading.Thread.Sleep(100)
'SendKeys.Send(0x2C)'
End If
End Sub[/php]
Originally Posted by Jason
Please, keep C++ in the C++ section for god's sake.
was bussy on a translation :>
Originally Posted by Kuro Tenshi
ahw... this SendKeys.Send(Keys.Printscreen) :/ well mine is below idk if this is correct /
[php]Public Class Main_Form 'or console app :/'
Public Declare Function GetAsyncKeyState Lib "user32" (ByVal vKey As Long) As Integer
Dim Exit as Boolean = GetAsyncKeystate("{E}")
Dim PRINTS as Boolean = GetAsyncKeyState("{S}")
Private Sub Main_Form_Load(Byval Sender as System.object, Byval e Systen.EventArgs) Handles Main_Form.Load
Timerx.Start
end sub
Private Sub Timerx_Start(Byval Sender as System.object, Byval e Systen.EventArgs) Handles Timerx.Start 'x = probably 1...'
if Exit = True then
Me.Close()
End If
if PRINTS = True then
SendKeys.Send(VK_SNAPSHOT)
Textboxx.Text += "SnapShot Taken." & VB_Return 'or something...'
System.Threading.Thread.Sleep(100)
'SendKeys.Send(0x2C)'
End If
End Sub[/php]
was bussy on a translation :>
Most of this won't even work as half of it is still C++
VB doesn't use the VK_ for keys, there's the keys class for that. also, 0x2C is the notation used in C++ but VB is &H2C, VB_Return doesn't exist. Why not open your IDE first and check if the code you're "helping" with actually compiles
Originally Posted by Jason
Most of this won't even work as half of it is still C++
VB doesn't use the VK_ for keys, there's the keys class for that. also, 0x2C is the notation used in C++ but VB is &H2C, VB_Return doesn't exist. Why not open your IDE first and check if the code you're "helping" with actually compiles
nahw i knowz didnt use the compiler + refining it :> + booleans not effective here either.
Originally Posted by Kuro Tenshi
nahw i knowz didnt use the compiler + refining it :> + booleans not effective here either.
So you knew that the code had no chance of compiling...what was the point in posting it then?
Originally Posted by Jason
So you knew that the code had no chance of compiling...what was the point in posting it then?
now i tested it the code it self @ the top was actually good enough but the problem was SendKeys doesnt work.
so prob the code that u posted first should be used then
btw whats wrong with C++ if it works eventhough its the wrong section it still does helps the person not /
Originally Posted by Kuro Tenshi
now i tested it the code it self @ the top was actually good enough but the problem was SendKeys doesnt work.
so prob the code that u posted first should be used then
btw whats wrong with C++ if it works eventhough its the wrong section it still does helps the person not /
For God's Sake Kallisti...
Originally Posted by Xscapism
For God's Sake Kallisti...
he is pspiso lol not kallisti
Originally Posted by Brinuz
he is pspiso lol not kallisti
OMG lol...but he acting like kallisti so...
Originally Posted by Kuro Tenshi
now i tested it the code it self @ the top was actually good enough but the problem was SendKeys doesnt work.
so prob the code that u posted first should be used then
btw whats wrong with C++ if it works eventhough its the wrong section it still does helps the person not /
What's wrong with posting a different language solution? /ed
It was asked for in this section, so clearly he wants to get a solution IN VISUAL BASIC not shit++ (just kidding, it's not shit /). It's like me going into the C++ section and posting windows forms solutions to fricken .dll problems It's not what he asked for.
@Hassan, he's the cool story bro guy
Lol, just call it using sendkeys, not that hard.. I tried it :3 I also made it so it creates an image with the clipboard data /me xD
But NO SPOONFEEDING is my rule now :$
Originally Posted by Hawk_
Lol, just call it using sendkeys, not that hard.. I tried it :3 I also made it so it creates an image with the clipboard data /me xD