#1071 SAMP13 Does Not Work

Samples (22)
Ken Barlow

I am trying to learn how to automate submitting a form on Internet Explorer (v 9.0.8112.16421) via OO REXX but can't get this sample to work. It doesn't add 'REXX' in the Search box on the IBM home page and doesn't submit the search. Is there something wrong with my installation?


  • Ken Barlow

    Ken Barlow - 2012-05-05

    The sample that I am referring to is located here: C:\Program Files\ooRexx\samples\ole\apps

  • jfaucher

    jfaucher - 2012-05-06

    Hi Ken

    The id of the search field has changed. We search for "Search", but the id is now "ibm-search".
    Tested with IE 7.0, the script is working as expected after this fix.
    Is it ok for you with IE 9.0 ?


  • Ken Barlow

    Ken Barlow - 2012-05-06

    It doesn't appear that I can downgrade my IE browser.

    I'm now using this line for the click (still doesn't work):

  • Ken Barlow

    Ken Barlow - 2012-05-07

    I've verified that it does work in IE 8.

  • Mark Miesfeld

    Mark Miesfeld - 2012-05-08

    The one certainty in this world is that things on the Internet change. This sample was probably written over 15 years ago, it's not surprising it doesn't work on a modern website.

    However, the samples are suppossed to give you an idea of how things work so you can write your own code. And in that regard the sample is still useful.

    It doesn't work for me on IE 9, it seems it is probably the click() method. You could still play around with the sample and get an idea of how the OLEObject works.

    For instance, you have this loop after the click() method:

    j = 1
    do i over all
    say 'i:' i~innertext
    j = j + 1

    Try sticking this line in the loop:

    if i~innertext~pos("REXX") > 0 then do

    so it looks like:

    j = 1
    do i over all
    say 'i:' i~innertext
    if i~innertext~pos("REXX") > 0 then do
    j = j + 1

    I get a bunch of print out like:

    i: IBM and Cisco
    i: IBM and Dassault SystΦmes
    i: IBM and Oracle
    i: IBM and SAP
    i: More alliances
    i: Business Partner solutions
    i: Find a Business Partner
    i: Business services
    i: Application innovation
    i: Business analytics
    i: Business strategy
    i: Commerce consulting
    i: Midmarket expertise
    i: All business services
    i: IT services
    i: Application management
    i: Business continuity and resiliency
    i: Cloud

    Which is enough to figure out that the click() for search didn't work, there is no Rexx in any one of the lines.

    Why don't you fool around with the sample some and see if you can fix it on IE 9?

  • Ken Barlow

    Ken Barlow - 2012-05-10

    Thanks for the sample code - I will try it this weekend.

  • Mark Miesfeld

    Mark Miesfeld - 2012-05-30

    Committed revision 7810.
    Committed revision 7811. Bug fix branch.

    This commit fixes the ID name used to get the search button element. It also adds some error handling if the website page has changed, and handles the case where the search does not get submitted.

    With IE9 on Windows 7, the search does not get sumbitted. This is not a bug in the OLEObject class, or the sample. The 'click' method is inovked without error. The invocation returns .true as the InternetExplorer.Application documentation indicates it should.

    The fact that the example program works with IE8 indicates to me that it may be that Microsoft has tightened up its security in IE9 and does not allow this type of scripting. I tried adjusting the security level to the most permissive allowable, and it still didn't work.

    I tried several other techniques, including getting the form itself and using the submit() method, which also should work according to Microsoft's documentation. Same results.

  • Mark Miesfeld

    Mark Miesfeld - 2012-09-07
    • status: pending --> closed
    • pending_work_items: --> none


Cancel  Add attachments

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks