FAQ Database Discussion Community


How to pause ffmpeg than runs without window?

vb.net,ffmpeg,backgroundworker,sendkeys,pausing-execution
I'm working on a video converter and I wanted to be able to stop or pause ffmpeg by pressing a button. Googleing I have found a way but it's not working. basically I Start ffmpeg on a background worker in this way: Private Sub bw_DoWork(ByVal sender As Object, ByVal e...

How to send outlook email automatically using Excel UserForm?

email,excel-vba,outlook-vba,sendkeys
Thanks for any help with this. I have a userform I've made that gathers criteria from the user and then when they hit submit it opens Outlook and emails that data to me. I'm having 2 issues. The first is that when I try to use SENDKEYS method I'm running...

Unpredictable results using sendkeys with capslock

c#,sendkeys
I would like to simulate a user input to prevent the screen from locking. public Form1() { aTimer = new System.Threading.Timer(OnTimedEvent, null, 5000, Timeout.Infinite); } private void OnTimedEvent(Object source) { Stopwatch watch = new Stopwatch(); watch.Start(); if (IdleTimeFinder.GetIdleTime() > 2000) { SendKeys.SendWait({CAPSLOCK}); } aTimer.Change(Math.Max(0, 5000 - watch.ElapsedMilliseconds), Timeout.Infinite); } My...

Why SendKeys.SendWait() crashes my application

c#,thread-safety,messaging,sendkeys
In my console application, SendKeys.SendWait("^c") is called to copy some selected text to the clipboard. It works fine, but if my console application has focus when this is called, then, instead of throwing an exception, it just closes my application. And then after that things start acting up, like my...

WshShell.SendKeys - SLASH not allowed?

vbscript,sendkeys
Today I am having difficulties with this following code: x=msgbox("Your Text Here" ,0, "Your Title Here") UserName=inputbox("After this message, you have 5 seconds to switch to Minecraft. Please enter the username you wish to type the song to:") wscript.sleep 5000 WshShell.SendKeys "/msg" + UserName + "I know that we just...

Alternative to SendKeys “{Esc}” for unbound text box Undo

ms-access,sendkeys
I have an unbound textbox control. The user enters some valid text and leaves the control. The user then returns to the control and enters some invalid text. I want to show the user a message then rollback the value of the control to its previous state and keep the...

Inconsistent result fron functional test with protractor

protractor,sendkeys
I created functional tests with protractor, and I get inconsistent results. sendKeys (in Chrome) provides inconsistent results. Sometimes the test fails, and sometimes the exact same test works. How can I use sendKeys and get consistent results? it('should add explanation', function() { browser.sleep(1000); topic.createExplanation(); browser.sleep(1000); expect(topic.items.count()).eventually.equal(1); }); it('should input text',...

Simulate keyboard click in GTA:SA

c#,winforms,sendkeys,intptr
I'm trying to run a program that sometimes will simulate clicks in GTA:SA. Problem is it doesn't do anything when running. I have tried this code so far: IntPtr calculatorHandle = FindWindow(null, "GTA:SA:MP"); if (calculatorHandle == IntPtr.Zero) { MessageBox.Show("GTA:SA:MP isn't running"); return; } SetForegroundWindow(calculatorHandle); SendKeys.SendWait("T123"); I'd be glad if you...

How to send Ctrl+S through SendKeys.Send() method to save a file(save as dialog)

c#,.net,windows,sendkeys
I need to save a file which is in an External application using SendKeys.Send() method. The keys needed to be sent are Ctrl+S. I wrote the below code, but its not working: SendKeys.SendWait("^%s?"); // to get the Save As dialog Thread.Sleep(5000); SetForegroundWindow(FindWindow(null, "Save As")); Thread.Sleep(5000); SendKeys.SendWait("xyz"); // Sending FileName ...

Emulate copy-paste from Keyboard wedge application in VB.net

vb.net,sendkeys,keyboard-wedge
We have an application (written in VB 2005) that reads incoming characters on a virtual serial port (on which a Cognex barcode scanner is connected), validate the stream and send it to the focused object using the SendKeyscommand. It has worked perfectly for years, but now customers have new software...

SendKeys alternatives?

c#,sendkeys,keyhook
I created a keypad app that stays on top, but does not take the focus so that on a touch screen it will forward whatever keys you press to the active application via SendKeys. It works perfectly with every application I have tried it with... except, of course, for the...

Sending keyboard key to browser in C# using sendkey function

c#,process,sendkeys
Hello i am trying to send a key to browser using the code below, the new chrome window opens for me but it does not send the key to the browser. When i debugged i found out chrome process does not have any title name how can i solve this...

How to close Firefox's current tab?

c#,firefox,sendkeys
I'm trying closing a current tab in firefox using C#. I use System.Windows.Forms.SendKeys("^W") to firefox and it closes all tab. However, I can send Ctrl + Tab to firefox by System.Windows.Forms.SendKeys("^{TAB}") and the current tab is changed. ...

VB.NET: How to maintain main form control during loops in other sub?

vb.net,forms,ffmpeg,sendkeys,loose
I have a program with only one form. By pressing a button it starts a ffmpeg conversion. In the main form, in textboxes, ffmpeg stats are outputted. This is possible by taking StandardError output from ffmpeg. Public Sub Console() Dim Process As New Process Process.StartInfo.UseShellExecute = False Process.StartInfo.RedirectStandardError = True...