Hi,
as has already been noted it's not possible to tell exactly what you're after however I've done stuff like this in MS Office apps before - it's not always straightforward to automate a Select-Copy-SwitchApp-Paste operation even within standard Office apps...

Assuming one of the apps is a MS Office app you should hit ALT+F11 and create a new module in the VBA IDE then figure out what you want to do with Application.SendKeys (using the Windows help to get the special characters for ALT/Ctrl etc) then, once you know what you want to do (doesn't really have to be quite working) try converting it to Perl (if that's the best solution)...

'This is VBA in Excel Dim thisBook as Workbook 'need to add ref in Tools/References Dim otherApp as Word.Application Set otherApp = GetObject("Work.Application") otherApp.Activate 'Send the keystrokes... Application.SendKeys "keystrokes"
and in Perl
use strict; use Win32::OLE; my $WordApp = Win32::OLE->GetActiveObject("Word.Application"); #blah blah

HTH - Mark


In reply to Re: Logical Macro w/ Perl by maa
in thread Logical Macro w/ Perl by Grygonos

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.