iMacros doesn't push button

Discussions and Tech Support related to automating the iMacros Browser or Internet Explorer from any scripting and programming language, such as VBS (WSH), VBA, VB, Perl, Delphi, C# or C++.
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
shaves
Posts: 77
Joined: Tue Apr 29, 2008 6:50 pm

iMacros doesn't push button

Post by shaves » Thu Aug 24, 2017 7:32 pm

I'm developing a macro to run a query in PeopleSoft Financials. So far I have been able to get the macro to open PeopleSoft, logon, navigate to the query screen, and fill in the prompts. This part works great. The next step is to push the button to run the query. Below is the code that is supposed to push the button. I have recorded 2 lines; 1 with automatic and 1 with expert mode. I have run this multiple times with one or the other lines.

The code runs without throwing any errors but the query doesn't run. I have opened the iMacros Browser and have manually completed these steps and have gotten the same results, e.g., the query doesn't run. I have navigated directly into PeopleSoft and the query runs.

Any suggestions or changes that I could make? Thanks for your help........

IM = ""
IM = "CODE:"
IM = IM + "TAB T=2" + vbNewLine
IM = IM + "SET !TIMEOUT 60" + vbNewLine
IM = IM + "TAG POS=1 TYPE=INPUT:BUTTON FORM=NAME:win1 ATTR=ID:#ICOK" + vbNewLine ' AUTOMATIC

OR

IM = ""
IM = "CODE:"
IM = IM + "TAB T=2" + vbNewLine
IM = IM + "SET !TIMEOUT 60" + vbNewLine
IM = IM + "TAG POS=1 TYPE=INPUT:BUTTON FORM=NAME:win1 ATTR=ONCLICK:submitAction_win1(this.form,'#ICOK');&&ID:#ICOK&&CLASS:PSPUSHBUTTON&&TYPE:button&&VALUE:View<SP>Results" + vbNewLine ' EXPERT

Here is the system info:

32 bit machine
iMacros 10.3
Windows 7
iMacros Browser
chivracq
Posts: 10301
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: iMacros doesn't push button

Post by chivracq » Fri Aug 25, 2017 3:07 am

shaves wrote:I'm developing a macro to run a query in PeopleSoft Financials. So far I have been able to get the macro to open PeopleSoft, logon, navigate to the query screen, and fill in the prompts. This part works great. The next step is to push the button to run the query. Below is the code that is supposed to push the button. I have recorded 2 lines; 1 with automatic and 1 with expert mode. I have run this multiple times with one or the other lines.

The code runs without throwing any errors but the query doesn't run. I have opened the iMacros Browser and have manually completed these steps and have gotten the same results, e.g., the query doesn't run. I have navigated directly into PeopleSoft and the query runs.

Any suggestions or changes that I could make? Thanks for your help........

Code: Select all

IM = ""
IM = "CODE:"
IM = IM + "TAB T=2" + vbNewLine
IM = IM + "SET !TIMEOUT 60" + vbNewLine
IM = IM + "TAG POS=1 TYPE=INPUT:BUTTON FORM=NAME:win1 ATTR=ID:#ICOK" + vbNewLine 
' AUTOMATIC

OR

Code: Select all

IM = ""
IM = "CODE:"
IM = IM + "TAB T=2" + vbNewLine
IM = IM + "SET !TIMEOUT 60" + vbNewLine
IM = IM + "TAG POS=1 TYPE=INPUT:BUTTON FORM=NAME:win1 ATTR=ONCLICK:submitAction_win1(this.form,'#ICOK');&&ID:#ICOK&&CLASS:PSPUSHBUTTON&&TYPE:button&&VALUE:View<SP>Results" + vbNewLine 
' EXPERT

Here is the system info:

Code: Select all

32 bit machine
iMacros 10.3
Windows 7
iMacros Browser
Hum..., can't do any Testing myself, even if I probably still still have some CD-Install for PS from when I was working for PS about 5 years ago, but I guess you are now 20 Versions further, ah-ah... Any Demo on Internet...?
Best Guess I would say is to try using the 'EVENT' Mode, but not available on iMB v10.3, only available from iMB v11 (?) or v11.5... (!)
Hum..., or try the 'DS' Mode, ah-ah...!

But your '.vbs' Script looks a bit "overkill" to me or "useless" if you prefer as it doesn't add any added Value to pure '.iim'... :roll:
=> Simply use FF or CR with the 'EVENT' Mode, I would think... :idea:
- (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...
shaves
Posts: 77
Joined: Tue Apr 29, 2008 6:50 pm

Re: iMacros doesn't push button

Post by shaves » Fri Aug 25, 2017 3:47 pm

Thanks for the suggestions. I'll give them a try......
shaves
Posts: 77
Joined: Tue Apr 29, 2008 6:50 pm

Re: iMacros doesn't push button

Post by shaves » Mon Aug 28, 2017 2:45 pm

Using version 11 and the EVENT command works. The next question I have is that I want to add a little script to identify if the user is using version 11.. In the past, we had a little script (see below) to identify if the user was on version 6 or 7 (I pulled this out of an old macro). I've tried to modify it to check for version 11. However, V11exe is always false and I need it to be true if the user has version 11. Currently, our users have version 10.3 or 11. The macro works for 11 but not 10.3 when pushing the button. I want to add this to the beginning of the macro and it will stop if v11exe is false and display a popup that you must have version 11 to use this macro. Any suggestions? Thanks of your help........

Sub iMacVersion()

v6Path = False
v6exe = False
v7Path = False
v7exe = False
v11Path = False
v11exe = False

Set ObjScr = CreateObject("Scripting.FileSystemObject")

v6Path = ObjScr.FolderExists("C:\Program Files\iMacros")
v7Path = ObjScr.FolderExists("C:\Program Files\iOpus\iMacros")
v11Path = ObjScr.FolderExists("C:\Program Files\Ipswitch\iMacros")
If v6Path = True Then v6exe = ObjScr.FileExists("C:\Program Files\iMacros\iMacros.exe")
If v7Path = True Then v7exe = ObjScr.FileExists("C:\Program Files\iOpus\iMacros\iMacros.exe")
If v11Path = True Then v11exe = ObjScr.FileExists("C:\Program Files\Ipswitch\iMacros\iMacros.exe")

Set ObjScr = Nothing

End Sub
chivracq
Posts: 10301
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: iMacros doesn't push button

Post by chivracq » Mon Aug 28, 2017 4:45 pm

shaves wrote:Using version 11 and the EVENT command works. The next question I have is that I want to add a little script to identify if the user is using version 11.. In the past, we had a little script (see below) to identify if the user was on version 6 or 7 (I pulled this out of an old macro). I've tried to modify it to check for version 11. However, V11exe is always false and I need it to be true if the user has version 11. Currently, our users have version 10.3 or 11. The macro works for 11 but not 10.3 when pushing the button. I want to add this to the beginning of the macro and it will stop if v11exe is false and display a popup that you must have version 11 to use this macro. Any suggestions? Thanks of your help........

Code: Select all

Sub iMacVersion()

v6Path = False
v6exe = False
v7Path = False
v7exe = False
v11Path = False
v11exe = False

Set ObjScr = CreateObject("Scripting.FileSystemObject")

v6Path = ObjScr.FolderExists("C:\Program Files\iMacros")
v7Path = ObjScr.FolderExists("C:\Program Files\iOpus\iMacros")
v11Path = ObjScr.FolderExists("C:\Program Files\Ipswitch\iMacros")
If v6Path = True Then v6exe = ObjScr.FileExists("C:\Program Files\iMacros\iMacros.exe")
If v7Path = True Then v7exe = ObjScr.FileExists("C:\Program Files\iOpus\iMacros\iMacros.exe")
If v11Path = True Then v11exe = ObjScr.FileExists("C:\Program Files\Ipswitch\iMacros\iMacros.exe")

Set ObjScr = Nothing

End Sub
Oh...!, I saw that one on SOF, and was thinking "OK, pity you didn't open a Thread on "our" Forum, I would have a Solution in pure "iMacros", ah-ah...!"...

But, hum..., this 2nd Qt has nothing to do with the original one and the Thread Title, can you rather open a separate Thread...? :idea:
Other Users searching the Forum later with a similar Qt won't try to check this Thread otherwise because they'll think the Thread is irrelevant...
- (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...
shaves
Posts: 77
Joined: Tue Apr 29, 2008 6:50 pm

Re: iMacros doesn't push button

Post by shaves » Tue Aug 29, 2017 1:09 pm

Sure............I added a new thread yesterday after reading your message. Thanks for the help..........
chivracq
Posts: 10301
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: iMacros doesn't push button

Post by chivracq » Tue Aug 29, 2017 3:39 pm

shaves wrote:Sure............I added a new thread yesterday after reading your message. Thanks for the help..........
Yep..., seen it... and answered it...
For anybody "curious" or interested, here is that Follow-up Thread... :wink:
- (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...
Post Reply