automation

Send Text in Clipboard to Application like Notepad (C# or Powershell)

爷,独闯天下 提交于 2020-01-03 14:27:12
问题 I want to be able to send the text on the clipboard, in Windows, to an application. For example, I'm working on a text file in notepad, and I want to copy a portion out into a new file..I want to copy it to the clipboard and then use a hotkey to launch an application or powershell script that sends that copied text to a new instance of Notepad. How can I achieve this in C# or Powershell ? SOLUTION: Using AutoHotKey ^+c:: Send ^c Run Notepad WinWait Untitled - Notepad WinActivate Send ^v

Word 2010 automation: 'goto bookmark'

纵饮孤独 提交于 2020-01-03 11:02:14
问题 I have a program written in Delphi-7 which opens a new Word document which is based on a template. Once the document is open, the automation jumps to a bookmark (predefined in the template) and adds some text there. The following code works fine in Word 2003 but causes a invalid variant operation error message in Word 2010 (I have omitted try/except blocks for the sake of clarity) . wrdapp:= CreateOleObject ('Word.Application'); wrdDoc:= wrdapp.documents.add (wrdApp.Options.DefaultFilePath

Word 2010 automation: 'goto bookmark'

a 夏天 提交于 2020-01-03 11:02:10
问题 I have a program written in Delphi-7 which opens a new Word document which is based on a template. Once the document is open, the automation jumps to a bookmark (predefined in the template) and adds some text there. The following code works fine in Word 2003 but causes a invalid variant operation error message in Word 2010 (I have omitted try/except blocks for the sake of clarity) . wrdapp:= CreateOleObject ('Word.Application'); wrdDoc:= wrdapp.documents.add (wrdApp.Options.DefaultFilePath

Answering a cli prompt in ruby with open3?

烂漫一生 提交于 2020-01-03 06:39:11
问题 Apologies for lack of sample code, I'm on mobile at the moment. I've gotten ruby+open3 to run commands and save stdout and stderr to a variable. My question is, if the command line interface prompts the user is it possible to input text into the prompt and press enter? If so how would I go about doing this. Example explanation Runs program, program in terminal then asks "what is your name?" and waits for input. I want to input a name, press enter. Then it asks next question, I want to put to

VB6 Automation Error on Calls to .NET 3.5 Assemblies After the First Calls

。_饼干妹妹 提交于 2020-01-03 05:04:18
问题 Some of the sources I've checked already: http://www.experts-exchange.com/Programming/Languages/.NET/Visual_Basic.NET/Q_23359339.html http://mygreenpaste.blogspot.com/2006/03/net-framework-20-configuration-tool.html http://support.microsoft.com/kb/186063 I'm busy developing .NET modules that will hook into our existing VB6 code. I've created a test VB6 project from which to launch the new code which comprises of a form with a button, and on the button's click event is Dim launcher As New

how to compare actual and expected values in angular js protractor

独自空忆成欢 提交于 2020-01-03 04:43:19
问题 In angular protractor automation,am trying to compare the values using "expect" but am not able to do it. In our application, after clicking on submit button the page is navigating to welcome page, so i want to get the expected value from the welcome page. This is the welcome page Html code <a class="link-btn ng-binding" title="new position" ng-click="openPositionModal($event)"><i class="icon-plus"></i> new position</a> please help me.. Thanks, Raghavendra 回答1: Just check if an element with

Calabash Android: Is there a special perform_action command for pressing the search button on the Android keyboard

筅森魡賤 提交于 2020-01-03 02:31:09
问题 The command perform_action('send_key_enter') sends the enter key but for our search field, the enter key is replaced by the search key in the Android keyboard. Is there a special perform_action command to send the input of the search key? 回答1: What could be happening is your scripts aren't able to accurately locate ADB in order to send the command to the device. Try using the following, which uses default_device.adb_command - this should use the full path to ADB and also use the proper device

How to automate interactive telnet commands?

青春壹個敷衍的年華 提交于 2020-01-02 18:54:51
问题 I would like to query a telnet server on port 105. What I have to do currently is start an interactive session and enter the commands later one by one. Since I already know the commands, I would like to automate this process and fetch the results without any manual intervention. When I try to use pipe to push commands at the time of logging in, this doesn't work. Any help is highly appreciated. 回答1: You are probably looking for a tool like expect. 回答2: Since you do not say what OS you use,

Ansible, Juniper CLI commands. Timeout Error?

守給你的承諾、 提交于 2020-01-02 09:52:28
问题 I am trying to transfer an automation script I made in Python, to ansible (company request), and I have NEVER worked with ansible before. I have tried the "wait_for:", but I have not gotten that to work either. In the script, I could set dev.timeout=None or whatever I needed. I am finding it hard to figure out where I can do this in ansible. I have tried setting the timeout in the "ansible.cfg" file. But that doesnt work. I can do simple commands, like: cli="show version", or cli="show system

element not interactable exception in selenium web automation

跟風遠走 提交于 2020-01-02 03:10:27
问题 In the below code i cannot send password keys in the password field, i tried clicking the field, clearing the field and sending the keys. But now working in any of the method. But its working if i debug and test public class TestMail { protected static WebDriver driver; protected static String result; @BeforeClass public static void setup() { System.setProperty("webdriver.gecko.driver","D:\\geckodriver.exe"); driver = new FirefoxDriver(); driver.manage().timeouts().implicitlyWait(60, TimeUnit