Jump to content
Macro Express Forums

sridharr

Members
  • Posts

    6
  • Joined

  • Last visited

Posts posted by sridharr

  1. I'm sorry, I do not have time to write a complete macro right now. I can give you some hints, however.

     

    You already know how to get the information to the clipboard and from the clipboard to a variable. The examples that follow assume the information from the entire screen is in T1. The next step is to 'parse' information one line at a time.

     

    On some computers, each line is terminated with a CR (carriage Return) followed by a LF (line feed). On other systems lines may be terminated by LF alone or (in rare cases) CR alone. It is also possible that information from your screen will not be terminated by CR or LF but, instead, be grouped in lines of 25 (or 132, or whatever) characters. You will need to determine this for your system. The best way to make this determination is to write a macro and observe how it works. The following sample assumes each line is terminated by CRLF.

     

    The first step of the parsing process is get CR and LF (CRLF) into a variable. This sample does just that:

    Variable Set %T13% to ASCII Char of 13  // Set T13 to CR
    Variable Set %T10% to ASCII Char of 10  // Set T10 to LF
    Variable Set String %T13% "%T13%%T10%"  // Set T13 to CRLF

    Then use something like this to find the first line:

    Variable Set Integer %N1% from Position of Text in Variable %T1%  // Put %T13% (containing CRLF) into the Search Text field of this command
    Variable Modify String: Copy Part of %T1% to %T2% // Save the result to N1

    At this point T2 will contain the first line. Now, delete the first line from T1:

    Variable Modify String: Delete Part of %T1%

    And repeat the steps above. If you want to preserve each line then you will want to place the result in T3 instead of T2.

     

    This should get you started. For more information study the variables documentation in the help. Good luck.

  2. Can you copy everything from the clipboard to a variable and then parse through the variable? Then the delay would only be 2 seconds. And then you may be able to reduce the remaining delay down from 2 seconds.

     

     

    Nice Idea. How to parse the text?

     

    My Text :

     

     

    · When changing the description ‘A’ to ‘T’ then Texas state exemption will be popped up.

    · Some of the groups (ADP, Gevity) should not be processed.

    · Match the renewal date with initial effective date

    Ø Check the day and month for Open Enrollment.

    Ø Check the day and month with the year for new group.

    · State Exemption Pop up including the P& P to be referred.

    · Time line for COBRA should be same for all the COBRA active dates.

    · EA=N; Inquiry date should be the first of the insurance month for all process.

    · In SGAR screen, Pop up should appear for the missing information or blank field in SGME.

    · In SGAR the impacted employees list also popped up.

     

     

    Parse any five text in the above Paragraph.

  3. Hi All,

     

    I need to copy 5 strings from emulator(Mainframe Window) .Please review my code.

     

    My Code :

     

    Variable Set String %T1% from Clipboard

    Delay 2 Seconds

     

    Variable Set String %T2% from Clipboard

    Delay 2 Seconds

     

    Variable Set String %T3% from Clipboard

    Delay 2 Seconds

     

    Variable Set String %T4% from Clipboard

    Delay 2 Seconds

     

    Variable Set String %T5% from Clipboard

    Delay 2 Seconds

     

     

    If delay is not given.Its not working as defined.So totally take 10 seconds delay+2 seconds for processing.

    For Manual copy, It takes only 8 second.

    Please improve my code ,if you have any idea.

    Thanks

    Sridhar R

  4. If the window is an Excel window or similar, I would suggest having the macro open the GoTo feature and go to row 3 column 5. Then use the Text Type command to Shift and Arrow Right to highlight the 11 cells and copy the highlighted cells to the clipboard. Use the Variable Set String command and save the clipboard contents to a text string variable.

     

     

    Nice Thinking. It is not an excel window. I am using mainframe window. Also this process takes time. If you have any other idea share with me.

  5. Hi All,

     

    Through Macro Express, I have active another window (Title :Emulator).In the active window i need one string. i.e I need 3 row 5 column to 3 row 15 column. After that i need to assign this string to new string Variable.How can I do this?

     

     

    Eg:

    In VB

    Dim a as string=application.gettext(3,5,3,15)

     

     

     

    Thanks in Advance.

×
×
  • Create New...