Clear default value in text Field

Discussions and Tech Support specific to the iMacros Firefox add-on.
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
Tamilselvan
Posts: 129
Joined: Mon Mar 07, 2016 10:49 am

Clear default value in text Field

Post by Tamilselvan » Wed Jul 19, 2017 8:05 am

Version 9.0.3
Windows 10
Firefox 50.1.0

How to clear default value in Text box.

Whenever i change / open value from drop down list default value is shown in text box.

I use following code : Manually it asked which row want to clear

VERSION BUILD=9030808 RECORDER=FX
TAB T=1

PROMPT Insert<SP>RowNo<SP>toClear :!VAR1

TAG POS={{!VAR1}} TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=
TAG POS={{!VAR1}} TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=

I need to clear default value in Text box automatically, While i am changing value from drop down list.

Please help.
Attachments
Clear Data.jpg
chivracq
Posts: 10301
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: Clear default value in text Field

Post by chivracq » Wed Jul 19, 2017 8:37 pm

Tamilselvan wrote:

Code: Select all

Version 9.0.3
Windows 10
Firefox 50.1.0
How to clear default value in Text box.

Whenever i change / open value from drop down list default value is shown in text box.

I use following code : Manually it asked which row want to clear

Code: Select all

VERSION BUILD=9030808 RECORDER=FX
TAB T=1

PROMPT Insert<SP>RowNo<SP>toClear :!VAR1

TAG POS={{!VAR1}} TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=
TAG POS={{!VAR1}} TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=
I need to clear default value in Text box automatically, While i am changing value from drop down list.

Please help.
You have a misplaced Space in this Line:

Code: Select all

PROMPT Insert<SP>RowNo<SP>toClear :!VAR1
Did you try using Double Quotes for an empty String like in?:

Code: Select all

TAG POS={{!VAR1}} TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=""
TAG POS={{!VAR1}} TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=""
You can probably do it using the 'EVENT' Mode with 'Ctrl^a' + 'Del'.

And don't follow up on this Thread 3 months later like in your previous Thread (hum, this current one is a bit a Duplicate/Follow-up actually, but OK...) or I won't try to help you anymore...
- (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...
Tamilselvan
Posts: 129
Joined: Mon Mar 07, 2016 10:49 am

Re: Clear default value in text Field

Post by Tamilselvan » Tue Jul 25, 2017 10:39 am

I want to clear text filed automatically while changing data from drop down list .
chivracq
Posts: 10301
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: Clear default value in text Field

Post by chivracq » Tue Jul 25, 2017 2:31 pm

Tamilselvan wrote:I want to clear text filed automatically while changing data from drop down list .
Oh...!, finally some Follow-up after 1 week now, you don't seem to be in a hurry to get your Script to work I guess...

Yep, I understand what your what but your Date Fields don't look like they are DDLB's, from the 'TYPE=INPUT:TEXT' in your Script and from the Screenshot.

And pfff..., you didn't react/try (to) any single Suggestion I made in my previous Post... :shock:
- (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...
Tamilselvan
Posts: 129
Joined: Mon Mar 07, 2016 10:49 am

Re: Clear default value in text Field

Post by Tamilselvan » Wed Jul 26, 2017 9:26 am

Sorry i was checking myself if any other issue in this regards to ask you. that's why i follow up / check later.

Here after i do not do like this.

Here is my code :

'Changing value from Drop Down List using csv file.
TAG POS={{!VAR4}} TYPE=SELECT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_DDL_Registration CONTENT=%*{{!COL1}}*
WAIT SECONDS=4

'Clear the text in unnecessary field '
PROMPT Insert<SP>RowNo<SP>toClear :!VAR1

TAG POS={{!VAR1}} TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=
TAG POS={{!VAR1}} TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=

Manually It ask row & clear text filed.
chivracq
Posts: 10301
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: Clear default value in text Field

Post by chivracq » Wed Jul 26, 2017 2:12 pm

Tamilselvan wrote:Sorry i was checking myself if any other issue in this regards to ask you. that's why i follow up / check later.

Here after i do not do like this.

Here is my code :

Code: Select all

'Changing value from Drop Down List using csv file.
TAG POS={{!VAR4}} TYPE=SELECT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_DDL_Registration CONTENT=%*{{!COL1}}*
WAIT SECONDS=4

'Clear the text in unnecessary field '
PROMPT Insert<SP>RowNo<SP>toClear :!VAR1

TAG POS={{!VAR1}} TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=
TAG POS={{!VAR1}} TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=
Manually It ask row & clear text filed.
Yeah but the 'Clear Text' part is the same as in your Post from 2 Posts earlier, to which I replied with several Suggestions but you didn't try/react to any of those Suggs... (I can only give some Suggs/generic Advice from some Script Excerpt and a Screenshot, I cannot test anything myself...)
- (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...
Tamilselvan
Posts: 129
Joined: Mon Mar 07, 2016 10:49 am

Re: Clear default value in text Field

Post by Tamilselvan » Sat Aug 05, 2017 11:29 am

Finally i got idea / solution.

Please help me

In drop down list each value has different No.of rows / records. I have stored in .csv file in nos. (how many records for each value.) (i.e) COL2.
1-Row.jpg
1-Row.jpg (30.87 KiB) Viewed 8613 times
2-Rows.jpg
2-Rows.jpg (32.27 KiB) Viewed 8613 times
3-Rows.jpg
3-Rows.jpg (27.22 KiB) Viewed 8613 times
i want to utilize !COL2 using loop.

Whenever i change value from drop-down list based on COL2 that rows will be cleared.

I don't know how to use loop instead of that i tried default rows (6 Nos.) to clear. But it takes time. For example if the value has 3 rows, Then first 3 code execute/cleared quickly, remaining 3 codes also execute then process will continues.

'Changing value from Drop Down List using csv file.
TAG POS={{!VAR4}} TYPE=SELECT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_DDL_Registration CONTENT=%*{{!COL1}}*
WAIT SECONDS=4

TAG POS=1 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=""
TAG POS=1 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=""

TAG POS=2 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=""
TAG POS=2 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=""

TAG POS=3 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=""
TAG POS=3 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=""

TAG POS=4 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=""
TAG POS=4 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=""

TAG POS=5 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=""
TAG POS=5 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=""

TAG POS=6 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=""
TAG POS=6 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=""
chivracq
Posts: 10301
Joined: Sat Apr 13, 2013 1:07 pm
Location: Amsterdam (NL)

Re: Clear default value in text Field

Post by chivracq » Sat Aug 05, 2017 12:46 pm

Tamilselvan wrote:Finally i got one idea / solution.

Please help me

In drop down list each value has different No.of rows / records. I have stored in .csv file in nos. (how many records for each value.) (i.e) COL2.
1-Row.jpg
2-Rows.jpg
3-Rows.jpg
i want to utilize !COL2 using loop.

Whenever i change value from drop-down list based on COL2 that rows will be cleared.

I don't know how to use loop instead of that i tried default rows (6 Nos.) to clear. But it takes time. For example if the value has 3 rows, Then first 3 code execute/cleared quickly, remaining 3 codes also execute then process will continues.

Code: Select all

'Changing value from Drop Down List using csv file.
TAG POS={{!VAR4}} TYPE=SELECT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_DDL_Registration CONTENT=%*{{!COL1}}*
WAIT SECONDS=4

TAG POS=1 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=""
TAG POS=1 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=""

TAG POS=2 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=""
TAG POS=2 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=""

TAG POS=3 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=""
TAG POS=3 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=""

TAG POS=4 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=""
TAG POS=4 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=""

TAG POS=5 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=""
TAG POS=5 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=""

TAG POS=6 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_app CONTENT=""
TAG POS=6 TYPE=INPUT:TEXT FORM=ID:aspnetForm ATTR=ID:ctl00_ContentPlaceHolder1_gvData_ctl*_dt_from CONTENT=""
Oh good, after more than 2 weeks, you finally tried the "CONTENT=""" Suggestion with an empty String and that works... Good...!

Would be nice btw if you could use the ]CODE[ Forum Meta-Tags to format your Posts a bit correctly (like I do in my Quotes), that would make the Thread a bit easier to read... :idea:

Yep, about "But it takes time...", simply use a short '!TIMEOUT_STEP' (=0), I would think...
- (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...
Tamilselvan
Posts: 129
Joined: Mon Mar 07, 2016 10:49 am

Re: Clear default value in text Field

Post by Tamilselvan » Mon Aug 07, 2017 6:32 am

Thank you very much. Its working.
Small request. Without double quotation code is also working. It just put empty value in text-filed.
Unfortunately i went to out of station Officially.

Thanks a lot for for your patient. :D
Post Reply