Parse fields from clipboard into web browser form fields

Hi there,

I have a linux command line script which I often run to create simple output in the following format:

field 1
field 2
field 3
field 20

I then manually copy paste these 20 fields, one-by-one, into their corresponding fields in a big web form. I’d like to be able to copy all 20 fields to my clipboard, then use a macro to paste them into the web form. How can I do this?

My thoughts:

  • The ordering of the script output fields and web form fields are always the same so it might be possible to tab-through the form and paste the fields from the clipboard one-by-one based on their order
    -Might it be possible to add an HTML tag to each element in the script output and parse those elements into variables using a macro then tab through the web form pasting the parsed variables in the correct order?


Try this (untested) approach:

  1. Read a File action (KM Wiki)
    . OR
    COPY selection, then Set Variable to clipboard
  2. Activate Browser (if you already have the page open)
    . OR
    Open a URL action (KM Wiki)
  3. Use a For Each action (KM Wiki) on a Variable with Lines Collection
  4. In the For Each block:
  5. Insert Text by Pasting using the Line
  6. Pause 0.1
  7. Type a Keystroke action (KM Wiki) with TAB
  8. Pause 0.1

NOTE: The pauses may have to be adjusted to fit the response of your system/web page.


1 Like