Forum Discussion

meesh610's avatar
meesh610
Occasional Contributor
7 years ago

Paste options while recording in script mode

Need help on how to paste data while in script mode?  Attached error and screen shot. 

 

Thanks!

  • Using, specifically, ctrl-V isn't necessary.  

     

    Basically, you don't want the ClickItem.  That won't do what you want.

     

    You need to send a "Keys" command to the desired text area.  As the parameter for that Keys, since you already have the contents in the clipboard, just put in Sys.ClipBoard and that will type into the desired field the contents of your clipboard.

  • cunderw's avatar
    cunderw
    Community Hero

    In your screenshots I don't see anything related to pasting, just ClickItem(undefined). You can't click undefined so that is why you are getting the error about a Control Item not being found.

     

    • meesh610's avatar
      meesh610
      Occasional Contributor

      Thank you.  When I inspect element I get the following:

       

      <textarea id="licensetext" class="licensetext ng-dirty ng-valid-parse ng-touched ng-empty ng-invalid ng-invalid-required" ng-model="licenseText" name="licensetext" required="x" rows="20" cols="80" form="form" style=""></textarea>

       

      But I need to be able to paste data to this text area via ctrl v (^v) or right mouse click paste from the pop up which is where I am running into issues. 

      • tristaanogre's avatar
        tristaanogre
        Esteemed Contributor

        Using, specifically, ctrl-V isn't necessary.  

         

        Basically, you don't want the ClickItem.  That won't do what you want.

         

        You need to send a "Keys" command to the desired text area.  As the parameter for that Keys, since you already have the contents in the clipboard, just put in Sys.ClipBoard and that will type into the desired field the contents of your clipboard.