How Extract Data in .NET Component

Discussions and Tech Support related to using the iMacros Component for .NET in your applications.

Moderators: Community Moderators, iMacros Moderators

Forum rules
Before asking a question or reporting an issue:
1. Please review the list of FAQ's.
2. Use the Google search box (at the top of each forum page) to see if a similar problem or question has already been addressed. This will search the entire contents of the forums as well as the iMacros Wiki.
3. We can respond much faster to your posts if you include the following information:

CLICK HERE FOR IMPORTANT INFORMATION TO INCLUDE IN YOUR POST

Answering your own posts (e.g. attempting to "bump" your topic) drops your topic from the list of unanswered threads, so it may actually receive less views.

How Extract Data in .NET Component

by chiaravel on Mon Sep 22, 2014 8:36 pm

Hi,

I have this code into a Sub.

Code: Select all
        Try
            im = iMacrosControl.Create(My.Settings.LicenciaIMACROS)

            t = "CODE: CLEAR"
            im.Play(t)

            t = "CODE: URL GOTO=https://accounts.google.com/ServiceLogin?service=adsense&rm=hide&nui=15&alwf=true&ltmpl=adsense&passive=false&continue=https://www.google.com/adsense/gaiaauth2?hl%3Des%26subid%3Dww-es-et-nelson_adsense&followup=https://www.google.com/adsense/gaiaauth2?hl%3Des%26subid%3Dww-es-et-nelson_adsense%26sourceid%3Daso&hl=es"
            im.Play(t)

            t = "CODE: TAG POS=1 TYPE=INPUT:TEXT FORM=ACTION:https://accounts.google.com/ServiceLoginAuth ATTR=NAME:Email CONTENT=xxxxxx@xxxxxxxx.com"
            im.Play(t)

            t = "CODE: SET !ENCRYPTION NO"
            im.Play(t)

            t = "CODE: TAG POS=1 TYPE=INPUT:PASSWORD FORM=ACTION:https://accounts.google.com/ServiceLoginAuth ATTR=NAME:Passwd CONTENT=xxxxxxxx"
            im.Play(t)

            t = "CODE: TAG POS=1 TYPE=INPUT:SUBMIT FORM=ACTION:https://accounts.google.com/ServiceLoginAuth ATTR=NAME:signIn"
            im.Play(t)

            t = "CODE: TAG POS=1 TYPE=DIV ATTR=CLASS:earnings-value EXTRACT=TXT"
            im.Play(t)

            t = "CODE: TAG POS=2 TYPE=DIV ATTR=CLASS:earnings-value EXTRACT=TXT"
            im.Play(t)

            t = "CODE: TAG POS=3 TYPE=DIV ATTR=CLASS:earnings-value EXTRACT=TXT"
            im.Play(t)

            t = "CODE: TAG POS=4 TYPE=DIV ATTR=CLASS:earnings-value EXTRACT=TXT"
            im.Play(t)

            Dim extract = String.Empty

            If im.ExtractedValues.Count > 0 Then
                extract = String.Join("[sep]", im.ExtractedValues.ToArray())
            End If

        Catch ex As Exception
            MsgBox(Err.Number.ToString + " " + Err.Description)
        End Try


But im.ExtractedValues.Count throw 0

What's Wrong ?

Thanks in advance
chiaravel
 
Posts: 9
Joined: Mon Sep 08, 2014 11:12 am

Re: How Extract Data in .NET Component

by joshi2014 on Wed Oct 22, 2014 1:07 am

Hi. I have an idea about it...

You using after every line of script the iim.play command, but You need to play a complete Macro once.

Solution:
Code: Select all
Dim MyMacro as String = "CODE clear" & vbNewline
MyMacro &= "SET! blabla" & vbNewline
MyMacro &= "URL blabla" & vbNewline
im.Play(MyMacro)

I just pointed out to make first the Macro String the Syntax is not right... but maybe that helps.

c.u. joshi
joshi2014
 
Posts: 3
Joined: Wed Oct 22, 2014 12:15 am

Re: How Extract Data in .NET Component

by chiaravel on Sun Nov 02, 2014 4:49 pm

Thanks Joshi

sorry for the delay..

But How can I take the control if I need to play all together ?

I need to check after every extract if the data is loaded..

this allow to us to make loop structures until data is extracted right.

I have a lot of problems running once..

I put a lot of seconds in TIMEOUT variables to run fine.. and a lot of times, the Imacros Component fail.

Are too much Flash sites, or intelligent platforms that user Ajax for give the info.

IMACROS haven't IF or WHILE statemens..

What can I do ?

Regards
chiaravel
 
Posts: 9
Joined: Mon Sep 08, 2014 11:12 am


Return to iMacros Component for .NET

Who is online

Users browsing this forum: No registered users and 1 guest

Website Monitoring