eresopo wrote:Hello chivracq
thanks for your quick reply and sorry for FCIM
Currently I'm developing on
Code: Select all
RHEL6 enviorment with Firefox 52.3.0 (64-bit) and Imacros for Firefox v.9.0.3.
Before starting with the csv approach, Prompt worked perfectly fine, user was typing his password and it was saving the password on the variable and doing everything ok.
When this week I started with the csv approach, I spent a while googling how to do the loop properly for 57 lines and after all, now it works, but on every loop is asking for the password.
I found that on vbs it was some way
but im not so expert with vbs
can you give me and advice or some help about it, what do you recommend to me
OK for FCI...
I didn't have the time to reply to your previous Post but other Advanced User @iimfun seems to have posted in the meantime a working Solution in pure '.iim'...
I was going to tell you to check a bit the Thread(s) I had referred to as it/they already contained/could lead to some possible Solution...
Concerning '.vbs', well..., yep that's a way to go indeed, like the way I mentioned using a '.js' Script. But for '.vbs' Scripts, you'll need the 'iMacros Scripting Interface' which belongs to the 'Enterprise Edition', while '.js' Scripts (in JavaScript) can be written and run on FF (only) using the Free iMacros for FF Add-on. So..., unless you have strong '.vbs' Knowledge in house, using a '.js' Script would look like an easier path to me, and you'll find a lot more Examples and Expertise of/with '.js' Scripts on the Forum than '.vbs' Scripts... (But on the other hand, if you buy the Enterprise Edition, you then have Access to Tech Support where they do have '.vbs' Expertise...)
iimfun wrote:And now the very conditional PROMPT.
Code: Select all
' 0 - No 1 - Yes
SET needPrompt 1
SET d EVAL("{{needPrompt}} ? '' : 'u';")
SET !ERRORIGNORE YES
PROMPT "Really need to enter a value?" promptVar EVAL({{d}})
SET !ERRORIGNORE NO
For those who still believe in miracles...
OK, looks promising, even if it took me a while to understand a bit how it works (your Syntax often looks a bit "obscure" @iimfun, would be handy if you could include some bits of Explanation sometimes), and it would be handy as well if you could mention in which FCI you've written/tested your Scripts, especially concerning the 'PROMPT' Functionality which works differently (or sometimes doesn't even work at all) between the different Browsers and even between different Versions of iMacros for FF...
But OK, I tested this Script in 2 different Versions of iMacros for FF and it works in both... Good News, ah-ah...!
The Trigger to get the (Conditional) 'INPUT PROMPT' is for the 'needPrompt' Var to have a +/- Decimal Value (or Integer of course) <> 0. (You don't get the 'PROMPT' for "0" (or "+/-0.000000") or a String.)
=> Adapted to @OP's Requirement to get the 'PROMPT' only for "!LOOP=1", that would give:
Code: Select all
VERSION BUILD=8820413 RECORDER=FX
TAB T=1
' 0 - No 1 - Yes
SET needPrompt EVAL("var d='{{!LOOP}}'; var z; if(d==1){z=1;} else{z=0;}; z;")
SET d EVAL("{{needPrompt}} ? '' : 'u';")
SET !ERRORIGNORE YES
PROMPT "Really need to enter a value?" promptVar EVAL({{d}})
SET !ERRORIGNORE NO
PROMPT LOOP:<SP>_{{!LOOP}}_<BR>needPrompt:<SP>_{{needPrompt}}_<BR>d:<SP>_{{d}}_<BR><BR>promptVar:<SP>_{{promptVar}}_
Tested (and works fine) on the following 2 FCI's:
Code: Select all
- iMacros for FF v8.8.2, Pale Moon v26.3.3 (=FF47), Win10_x64.
- iMacros for FF v8.9.7, FF v55.0.3, Win10_x64.
... And I would expect it to work as well on v9.0.3 for FF.
I was a bit surprised btw to notice that 'promptVar' retained between the different Loops, the Value that was entered in the 'PROMPT' in Loop_1. I always understood that all '!VARn' and User Defined Vars were reset (by Design) between Loops. Same Result with '!VAR1' instead of a User Defined Var...
But OK..., in order not to "pollute" this Thread too much away from @OP's original Qt/Need, I will post my further Comments (and was going to link to this Thread anyway) in the "main" Thread about 'PROMPT' I already referred to... Direct Link:
-
PROMPT Messagebox - Yes - No - Cancel (end)
- (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...