Different behavior when executing same macro

Discussions and Tech Support related to using the iMacros Component for .NET in your applications.
Forum rules
iMacros EOL - Attention!

The renewal maintenance has officially ended for Progress iMacros effective November 20, 2023 and all versions of iMacros are now considered EOL (End-of-Life). The iMacros products will no longer be supported by Progress (aside from customer license issues), and these forums will also no longer be moderated from the Progress side.

Thank you again for your business and support.

Sincerely,
The Progress Team

Before asking a question or reporting an issue:
1. Please review the list of FAQ's.
2. Use the search box (at the top of each forum page) to see if a similar problem or question has already been addressed.
3. Try searching the iMacros Wiki - it contains the complete iMacros reference as well as plenty of samples and tutorials.
4. We can respond much faster to your posts if you include the following information: CLICK HERE FOR IMPORTANT INFORMATION TO INCLUDE IN YOUR POST
Post Reply
hexinx
Posts: 3
Joined: Sat Aug 01, 2015 12:08 pm

Different behavior when executing same macro

Post by hexinx » Sun Aug 02, 2015 5:21 am

I'm executing the following macro from inside VB.net using the iMacros component for .NET

Code: Select all

VERSION BUILD=10.4.28.1074
TAB T=1
TAB CLOSEALLOTHERS
URL GOTO=http://ieeexplore.ieee.org/xpl/articleDetails.jsp?arnumber=6900914
SET !WAITPAGECOMPLETE YES 
TAG POS=1 TYPE=H1 ATTR=* EXTRACT=TXT
Windows 8. Internet Explorer.

This retrieves the name of the manuscript from IEEE Xplore. This works perfectly when run with iMacros browser/editor. But, when executing the script from inside Vb.net using the component, it gives me a "#EANF#" (Extraction Anchor Not Found).

I'm confounded.
chivracq
Posts: 10301
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: Different behavior when executing same macro

Post by chivracq » Sun Aug 02, 2015 2:55 pm

hexinx wrote:I'm executing the following macro from inside VB.net using the iMacros component for .NET

Code: Select all

VERSION BUILD=10.4.28.1074
TAB T=1
TAB CLOSEALLOTHERS
URL GOTO=http://ieeexplore.ieee.org/xpl/articleDetails.jsp?arnumber=6900914
SET !WAITPAGECOMPLETE YES 
TAG POS=1 TYPE=H1 ATTR=* EXTRACT=TXT
Windows 8. Internet Explorer.

This retrieves the name of the manuscript from IEEE Xplore. This works perfectly when run with iMacros browser/editor. But, when executing the script from inside Vb.net using the component, it gives me a "#EANF#" (Extraction Anchor Not Found).

I'm confounded.
My 2cts as I don't use the .NET Component...:

If you want '!WAITPAGECOMPLETE' to do stg, you should place it before the 'URL GOTO' Statement, I would think... :o

'!WAITPAGECOMPLETE' is only supported on iMacros for IE and the iMacros Browser, if I run your little Macro on iMacros for FF (v8.8.2) after having disabled the '!WAITPAGECOMPLE' Statement, it works fine and does extract the 'H1' Element you are after...

All 4 Browsers (iMacros Browser + IE + FF + CR) have some Default '!TIMEOUT_PAGE' (=60 sec) and '!TIMEOUT_STEP' (=6 sec) Settings/Values (that you can change), but I'm not sure if the .NET Component is able to access those Default Settings, maybe you could try hard-coding those 2 Settings at the beginning of your Macro (and try with and without '!WAITPAGECOMPLETE' to see if it makes a difference...).
- (F)CI(M) = (Full) Config Info (Missing): iMacros + Browser + OS (+ all 3 Versions + 'Free'/'PE'/'Trial').
- FCI not mentioned: I don't even read the Qt...! (or only to catch Spam!)
- Script & URL help a lot for more "educated" Help...
hexinx
Posts: 3
Joined: Sat Aug 01, 2015 12:08 pm

Re: Different behavior when executing same macro

Post by hexinx » Sun Aug 02, 2015 3:42 pm

First of all, thanks so much for the noticing the mistakenly placed !WAITPAGECOMPLETE statement ;)

I just realized what the problem was. It's the whole IE version thing.

IEEE Xplore doesn't work when viewed with an older version of IE. The component works under the guise of IE 7, I understand. That's why my program gives a #EANX# when executing the same code. I tried doing the exact same thing as the guidelines said, that is, the registry entry to mark my program to have the guise of IE 11. But, my program still behaves likes it working on IE 7. *my head hurts*.

A possible thought: How I specify the exe to the registry when running my program in debug mode? xyz.exe or xyz.vshost.exe or something? (I tried both, though)

P.S., thanks a bunch for replying, man =)

UPDATE: I built a release version and placed the exact same name in the registry (I actually used the sample VB.net project). It still didn't work.

UPDATE 2: YES. I FIXED IT LOL. The problem was that I was entering my program's name as a "QWORD" instead of "DWORD". Man, that one letter turned my entire evening upside down.

Thanks again, man.. =)
Post Reply